Since it is no longer in the repository, I can't do
git log <filename>
I can run
git log --diff-filter='D|R' <directory_that_contained_it>
but that is too much information and grepping it does not seem to list the file I'm looking for.
Since it is no longer in the repository, I can't do
git log <filename>
I can run
git log --diff-filter='D|R' <directory_that_contained_it>
but that is too much information and grepping it does not seem to list the file I'm looking for.
git log -1 --stat -- <path/to/file>
I put the --stat
in there so that you can verify that the file was deleted.
git log -- <filename>
will show you the changes to that path, even if that file isn't present any more.
You can use the rev-list -n 1
to limit it to the first result returned, which will be the one where it disappeared
git rev-list -n 1 HEAD -- <filename>
That revision is when it disappears, so you can find the parent if you want to restore it with ^ on that revision number