Home

Awesome

GitHub Actions for WordPress!

Here is a collection of GitHub Actions and workflows to help with common needs for WordPress development. Specific documentation for each Action is in its respective respository, and other example workflows leveraging existing Actions can be found in this repository. Ideas for future Actions can be found in issues.

Support Level MIT License

More information about GitHub Actions

Ready to use

The following GitHub Actions are published, available to use, and actively supported by 10up.

Deploying a plugin to the WordPress.org repository

Support Level Release Version MIT License

Whenever you tag a new version of your plugin on GitHub, your changes will be committed to both trunk and the appropriate tags subfolder in your WordPress.org plugin repository.

WordPress.org Plugin Build Zip Archive

Support Level Release Version MIT License

This Action will build a zip archive of your WordPress plugin and attach that archive as an artifact, allowing you to download and test prior to deploying any changes to WordPress.org. This gives you the peace of mind knowing you've tested exactly what will be deployed. Recommended to be used in conjunction with our WordPress.org Plugin Deploy Action as both Actions create the archive in the same way. An ideal workflow is to run this Action first and test the zip archive it provides. Once testing passes, then run our deploy Action to push changes to WordPress.org.

Deploying plugin asset/readme updates to the WordPress.org repository

Support Level Release Version MIT License

If you push to your specified branch and it only contains changes to the WordPress.org assets directory (defaults to /.wordpress-org) or readme.txt, deploy those changes to the WordPress.org plugin repository. This is useful for being able to update things like screenshots or the Tested up to version in between tagged releases.

PHP linting without additional codebase dependencies

Support Level Release Version MIT License

This action will run PHPCS (PHP_CodeSniffer) against WordPress Coding Standards and show warnings and errors as annotations in your PRs without adding PHPCS as a dependency or a PHP CodeSniffer config.

Deploying WordPress sites to Pantheon

Support Level Release Version GPLv3 License Automated Tests

The code in Pantheon's git main branch is production ready (preprod and production environments only) therefore our preferred deployment workflow for GitHub + Pantheon sites is:

WordPress Scanner Action

Support Level Release Version MIT License Automated Tests

GitHub Action to perform various checks for WordPress sites (Syntax, Virus, known vulnerabilities). This Action leverages our own WP-CLI Vulnerability Scanner to perform the known vulnerabilities scanning of WordPress plugins and themes. WP-CLI Vulnerability Scanner works with WPScan, Patchstack and Wordfence Intelligence to check reported vulnerabilities; you can choose any one of these three to use. Note: Authentication is optional for the Wordfence Intelligence Vulnerability API.

Automating repository operations

Support Level Release Version License CodeQL

This action automates some common repository operations, such as validating PR description, adding labels, auto-assigning issues, auto-requesting reviews on PRs, adding milestones, and many more.

Publishing generated hook documentation to GitHub Pages

If you follow the JSDoc standard for your custom WordPress actions and filters, you can use this workflow to generate documentation for your theme/plugin and publish them to GitHub Pages. For an example of the output, see the Distributor hook docs. The linting workflow of Block for Apple Maps is a good example how to use this action in practice.

Validating project dependency licensing

If you publish projects that adhere to a certain license (e.g. GPLv2), then you will want to ensure any dependencies within your project adhere to a compatible license. We've crafted a GitHub Action workflow and GPL-Compatible License Policy file that can be leveraged to ensure your projects are GPL-compatible. Additional license policy files could be developed to ensure other licensing are valid (e.g. a MIT-Compatible License Policy file).

Using markdown content in GitHub Actions summary

In May 2022, GitHub introduced the markdown support for the GitHub Actions summaries. This feature can help improve the developer experience by generating more useful reports to action summaries.

Planned

Contributing

Want to help? Check out our contributing guidelines to get started.

Support Level

Active: 10up is actively working on this, and we expect to continue work for the foreseeable future including keeping tested up to the most recent version of WordPress. Bug reports, feature requests, questions, and pull requests are welcome.

Like what you see?

<p align="center"> <a href="http://10up.com/contact/"><img src="https://10up.com/uploads/2016/10/10up-Github-Banner.png" width="850"></a> </p>