Stash unstaged changed before running tests
Closed this issue · 2 comments
tomfuertes commented
Helps test only prospective commit.
$ npm test # runs jshint
$ echo "// pass" > pass.js
$ echo "err()" > fail.js
$ git add pass.js
$ npm test # should fail on fail.js
$ git commit -m "should pass"
3rd-Eden commented
As the referred article's comments states, there are some serious flaws when it comes to stashing commits. So i'm not fully convinced this is the right way to handle this edgecase?
As a developer, you could just do git stash && git commit
when you have unstaged commits that breaks stuff.
tomfuertes commented
Err, didn't see comments w/ Ghostery. Good point!