Last active
November 2, 2015 18:44
-
-
Save shirlston/2faa4944ccee9f60f8f1 to your computer and use it in GitHub Desktop.
Rubo: Execute rubocop on ruby files that match a regex
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
#!/bin/bash | |
# rubo | |
# rubo(cop) | |
# Execute rubocop on ruby files that match a regex | |
# syntax: | |
# rubo <file regex> | |
git diff --name-only `git merge-base origin/master HEAD` | grep $1 | grep rb | xargs rubocop |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment