Created
May 1, 2015 21:25
-
-
Save greggles/dc14aba7222c2cece348 to your computer and use it in GitHub Desktop.
Find code style errors in modules in the subdirectory
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
find . -type d -d 1 -exec phpcs --standard=Drupal --extensions='php,module,inc,install,test,profile,theme,js,css,info,txt' --report-file={}_new.txt {} \; | |
# typical output: | |
# mani:contrib-patched greggles$ ls -lS *.txt | |
# -rw-r--r-- 1 greggles staff 10970 May 1 15:21 password_policy_style_issues.txt | |
# -rw-r--r-- 1 greggles staff 4887 May 1 15:21 code_coverage_style_issues.txt | |
# -rw-r--r-- 1 greggles staff 2681 May 1 15:21 quantcast_style_issues.txt | |
# mani:contrib-patched greggles$ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This assumes you've installed the coder module https://www.drupal.org/project/coder
Of course the linter (phpcs ...) could be swapped if you use JavaScript or whatevs.