I am looking for the commit that introduced Hello world into by codebase. git log -S"Hello world" is too slow due to the size of my codebase. Instead, as I know that this is in c.txt, I use git log -S"Hello world" -- c.txt. It turns out that this was actually moved from b.txt in a commit. So I do git log -S"Hello world" -- b.txt. Now I discover that it has been copied from a.txt. After git log -S"Hello world" -- a.txt I find the orignal commit that introduced this into the codebase.
Is there a way to have one command that finds all those commits?
Note that a.txt has not been copied in its entirety, only Hello world was copied out. Similarly, not all of b.txt has been renamed to c.txt, only parts were moved there.