This question is closely related to List all commits for a specific file however it is different. I want to find out which commits, across all branches, had
You can use gitk
gitk --all (you need to install gitk)
e.g.
gitk --all -- /home/kit.ho/project/abc.txt