Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Another thing you can do when you have two versions, one which fails and one which doesn't, but where the commits are of the messy work in progress nature and not atomic changes, is gradually stage the changes from the bad version onto the good version until it starts failing

Basically git checkout -p until things fail



That's a smart way to do it. When I was in this situation without having thought of that, I ended up chunking the monster commit into as small changes as possible with `git add -p`, and then used git rebase as my bisect (since I didn't know how bisect worked either) by rewinding through time until i had found the micro-commit that contained the error.


Thanks for the comment! It looks to be a very useful tip for doing after bisect on repositories where people insist to squash pull requests.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: