git bisect
is a really useful tool when you want to answer the question "when did this thing change?" but it's hard to understand from just looking at the git logs.
The way git bisect
works is that you define a "good" and a "bad" commit. The git bisect
command then uses a binary search to narrow down the commit that made the repository go from "good" to "bad".
You can further make your life easier by asking git bisect
to execute a script for you on each commit, automating the search, and providing the commit in question with no further manual intervention.
Below is an example, with an example script, that illustrates how git-bisect
was used on the 121-platform to find the answer to the question "when did typeorm start generating nonsense migrations?".