phpcompat icon indicating copy to clipboard operation
phpcompat copied to clipboard

Add/GitHub Linting action

Open jeffpaul opened this issue 4 years ago • 1 comments

Description of the Change

This PR adds in GitHub Actions to help with automation relating to:

  • PHPCS linting (eslint and other linting can be added in as desired)
  • Deploying plugin releases to WordPress.org
  • Deploying minor readme.txt and asset changes to WordPress.org (helpful when bumping the "Tested up to:" value for major WordPress release compatibility testing)

This will require adding GitHub repository secrets for SVN_USERNAME and SVN_PASSWORD for an account that has commit access for the plugin on WordPress.org SVN. I recommend having a company/org account, essentially one NOT linked to a specific person, so that releases/updates can continue without being blocked by a specific person moving off the project.

Most notably the PR does NOT add in a testing action given how complex the existing CircleCI integration is. However getting that test process ported into the sample test action linked just previously would even further reduce tooling dependencies to just GitHub.

I'd similarly recommend a new develop branch off master that's set as the default branch for the repo and that future releases essentially merges develop into master (more on that here). Further, I'd recommend to use the GitHub branch renaming to rename master to something like trunk or main to avoid using the "master" term. I'm happy to help scan the repo for places that need branch references updated, just let me know!

Alternate Designs

Continue to run linting and handle WordPress.org SVN updates elsewhere.

Benefits

Further automates what can be heavily manual processes, also standardizes all checking/testing/linting to within GitHub to help reduce tooling.

Possible Drawbacks

None identified.

Verification Process

Manually verified via VS Code and GitHub Desktop UI.

Checklist:

  • [ ] My code follows the code style of this project.
  • [x] My change requires a change to the documentation.
  • [x] I have updated the documentation accordingly.
  • [ ] I have added tests to cover my change.
  • [ ] All new and existing tests passed.

Applicable Issues

none identified

Changelog Entry

### Added
- Plugin linting, releasing, and updating automation via GitHub Actions (props [@jeffpaul](https://github.com/jeffpaul/))

jeffpaul avatar May 05 '21 17:05 jeffpaul

Since this repo uses Circle CI for WP.org deploys, I've removed those two GH Actions from this PR and limited the PR to the Linting action.

jeffpaul avatar Jul 20 '22 16:07 jeffpaul