Skip to content

Instantly share code, notes, and snippets.

@lloc lloc/gist:6650222
Created Sep 21, 2013

Embed
What would you like to do?
Install WordPress Coding Standards for PHP_CodeSniffer in Ubuntu
# Install PHP_CodeSniffer
sudo apt-get install php-codesniffer
# Install the WordPress Coding Standards
sudo git clone git://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards.git \
$(pear config-get php_dir)/PHP/CodeSniffer/Standards/WordPress
# Now your can check your files like this
phpcs --standard=WordPress your-file.php
# or you could set the WordPress Coding Standards as your default
sudo phpcs --config-set default_standard WordPress
# and use the CodeSniffer like so
phpcs your-file.php
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.