-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Resolve the vendor/wordpress-autoload.php file on Windows, add PHP 8.1-8.2 support #29
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few questions, no blockers - thanks for the quick fix! 🍣
|
||
jobs: | ||
test: | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: true | ||
matrix: | ||
os: [ubuntu-latest] | ||
php: [7.4, 8.0, 8.1] | ||
os: [ubuntu-latest, windows-2019] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
😮
on: | ||
push: | ||
branches: | ||
- main |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will also trigger after the PR is merged. Is that intentional?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I prefer to always have a status check on the main
branch to get a valid status badge.
preg_replace('#/vendor/.*$#', '/vendor/wordpress-autoload.php', __DIR__), | ||
preg_replace('/\\\vendor\\\.*$/', '/vendor/wordpress-autoload.php', __DIR__), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks like one too many backslashes - shouldn't it be like this?
preg_replace('/\\\vendor\\\.*$/', '/vendor/wordpress-autoload.php', __DIR__), | |
preg_replace('/\\vendor\\.*$/', '/vendor/wordpress-autoload.php', __DIR__), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not a regex pro to know but in testing with C:\Users\Sean Fisher\Local Sites\wordpress\app\public\wp-content\vendor\alleyinteractive\composer-wordpress-autoloader\src
as the __DIR__
:
four slashes: preg_replace('/\\\vendor\\\.*$/', '/vendor/wordpress-autoload.php', __DIR__),
-> "C:\Users\Sean Fisher\Local Sites\wordpress\app\public\wp-content/vendor/wordpress-autoload.php
two slashes: preg_replace('/\\vendor\\\.*$/', '/vendor/wordpress-autoload.php', __DIR__),
-> C:\Users\Sean Fisher\Local Sites\wordpress\app\public\wp-content\vendor\alleyinteractive\composer-wordpress-autoloader\src
/shrug
Changed
Fixed
wordpress-autoload.php
file not properly loading on Windows.Fixes #28