-
Notifications
You must be signed in to change notification settings - Fork 86
Closed
Labels
bugcommand:scaffold-pluginRelated to 'scaffold plugin' commandRelated to 'scaffold plugin' commandscope:testingRelated to testingRelated to testingstate:unconfirmed
Description
Bug Report
- Yes, I reviewed the contribution guidelines.
- Yes, more specifically, I reviewed the guidelines on how to write clear bug reports.
Describe the current, buggy behavior
The generated output in .github/workflows/testing.yaml fails for two reasons:
- The line
php-version: ${{ matrix.php-version }}is interpreted as handlebar delimeters and is output asphp-version: $, causing the following error in the "Setup PHP" step:PHP Could not setup PHP $.0 - Once the php-version is corrected manually, you get a second error in the "Setup tests" step:
Error: svn is not installed. Please install svn and try again.
Describe how other contributors can replicate this bug
- Use
wp scaffold plugin sample-plugin --ci=githubto create a new plugin with GitHub actions configured. - Initialize as a new repo, add all, commit, and push to main in a new GitHub repo
- Create a new feature branch
- Remove
<exclude>./tests/test-sample.php</exclude>line fromphpunit.xml.distso the sample test will run. - Commit and push the feature branch to origin.
- On GitHub, create a new pull request from the feature branch.
- The actions will start, and all three will fail.
Describe what you would expect as the correct outcome
I would expect three actions to run and succeed, one for each version of PHP in the test matrix.
Let us know what environment you are running this on
OS: Darwin 25.3.0 Darwin Kernel Version 25.3.0: Wed Jan 28 20:54:55 PST 2026; root:xnu-12377.91.3~2/RELEASE_ARM64_T8132 arm64
Shell: /bin/zsh
PHP binary: /opt/homebrew/Cellar/php@8.3/8.3.30/bin/php
PHP version: 8.3.30
php.ini used: /opt/homebrew/etc/php/8.3/php.ini
MySQL binary:
MySQL version:
SQL modes:
WP-CLI root dir: phar://wp-cli.phar/vendor/wp-cli/wp-cli
WP-CLI vendor dir: phar://wp-cli.phar/vendor
WP_CLI phar path: phar:///Users/andrewshell/bin/wp
WP-CLI packages dir:
WP-CLI cache dir: /Users/andrewshell/.wp-cli/cache
WP-CLI global config:
WP-CLI project config:
WP-CLI version: 2.12.0
Provide a possible solution
At the top of plugin-github.mustache, you can add: {{=<% %>=}} to change the delimiters.
Then add a new step before "Setup tests" that installs SVN:
- name: Install SVN
run: sudo apt-get update && sudo apt-get install -y subversionReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugcommand:scaffold-pluginRelated to 'scaffold plugin' commandRelated to 'scaffold plugin' commandscope:testingRelated to testingRelated to testingstate:unconfirmed