Skip to content

Instantly share code, notes, and snippets.

@packrat386
Created January 13, 2023 18:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save packrat386/34612ac856d965419ac368018da91910 to your computer and use it in GitHub Desktop.
Save packrat386/34612ac856d965419ac368018da91910 to your computer and use it in GitHub Desktop.
run rubocop on diff
#!/usr/bin/env bash
bundle exec rubocop --force-exclusion --only-recognized-file-types -A $(git diff --name-only $(git merge-base develop HEAD) | xargs -I _ bash -c 'if test -f _; then echo _; fi')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment