Skip to content
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

Adopt and enforce new WP_CLI_CS standard #45

Closed
3 tasks done
schlessera opened this issue Apr 17, 2019 · 1 comment
Closed
3 tasks done

Adopt and enforce new WP_CLI_CS standard #45

schlessera opened this issue Apr 17, 2019 · 1 comment
Milestone

Comments

@schlessera
Copy link
Member

schlessera commented Apr 17, 2019

We have a new PHPCS standard for WP-CLI called WPCliCS (props @jrfnl). It is part of the wp-cli/wp-cli-tests package starting with version v2.1.0.

To adopt & enforce this new standard, the following actions need to be taken for this repository:

  • Create a PR that adds a custom ruleset phpcs.xml.dist to the repository

    • Add phpcs.xml.dist file
    • Adapt .distignore to ignore phpcs.xml.dist & phpunit.xml.dist
    • Adapt .gitignore to ignore phpunit.xml, phpcs.xml & .phpcs.xml
    • Require version ^2.1 of the wp-cli/wp-cli-tests as a dev dependency
  • Make any required changes to the code that fail the checks from the above ruleset in separate PRs

  • Merge thre ruleset once all required changes have been processed and merged

A sample PR for a simple repository can be seen here: https://github.com/wp-cli/maintenance-mode-command/pull/3/files

Related wp-cli/wp-cli#5179

@schlessera schlessera changed the title Adopt and enforce new WPCliCS standard Adopt and enforce new WP_CLI_CS standard Apr 19, 2019
@schlessera
Copy link
Member Author

Fixed via #47

@schlessera schlessera added this to the 2.0.2 milestone Apr 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant