I had somewhere in my Git repository a line containing word "Foo" a couple hundreds commits before.
If there is any way to find its revision number where it was the last time without buying FishEye?
I had somewhere in my Git repository a line containing word "Foo" a couple hundreds commits before.
If there is any way to find its revision number where it was the last time without buying FishEye?
That may be addressed by the pickaxe (-S
) option of gitlog
git log -SFoo -- path_containing_change
(you can even add a time range: --since=2009.1.1 --until=2010.1.1
)
-S<string>
Look for differences that introduce or remove an instance of
<string>
.
Note that this is different than the string simply appearing in diff output; see the pickaxe entry in gitdiffcore(7) for more details.
diffcore-pickaxe
This transformation is used to find filepairs that represent changes that touch a specified string.
Whendiffcore-pickaxe
is in use, it checks if there are filepairs whose "original" side has the specified string and whose "result" side does not.
Such a filepair represents "the string appeared in this changeset".
It also checks for the opposite case that loses the specified string.