Skip to content

Instantly share code, notes, and snippets.

@rwjblue
Last active May 17, 2021 15:18
Show Gist options
  • Save rwjblue/4747973 to your computer and use it in GitHub Desktop.
Save rwjblue/4747973 to your computer and use it in GitHub Desktop.
Run rspec only on uncommited files. No more accidentally pushing a :focus tag to master!
rspec `git ls-files --modified --others spec`
@frank-who
Copy link

If you have factories and fixtures, you can try this

be rspec `git ls-files --modified --others spec/**/*_spec.rb`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment