Install the WordPress Coding Standards (WPCS), WordPressVIPMinimum, and PHPCompatibility sniffs for use with PHPCS.
Install the sniffs, with git, into home dir…
cd ~
git clone https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards.git
git clone https://github.com/Automattic/VIP-Coding-Standards.git
git clone https://github.com/wimg/PHPCompatibility.git
Update PHPCS config to see the sniffs (note that multiple paths require comma, no space, between them, space causes PHPCS to barf)…
phpcs --config-set installed_paths /Users/YOURUSERNAME/WordPress-Coding-Standards,/Users/YOURUSERNAME/VIP-Coding-Standards,/Users/YOURUSERNAME/PHPCompatibility
If you intend to use this for a WP theme, have a look at Underscore's phpcs.xml