File history is often too wide. What I usually want is the history of one function.
git log -L :parseConfig:src/config.js
The -L option traces the evolution of a line range or a function inside a file. With :name:file git takes a regular expression for the function name and follows that function. You get a list of commits, each with only the patch that touched that function. The docs say it implies --patch.
You can also use line numbers, which works for anything that is not a function:
git log -L 40,60:src/config.js
Compare that with git log -p src/config.js, which shows every change to the whole file. For a big file that is a lot of scrolling past changes you do not care about.
A few caveats. You cannot add a path filter on top of -L, and it works from a single starting revision. Git finds function boundaries the same way it picks the hunk headers in a diff, so for a language git does not know, you may need to set a funcname pattern in gitattributes, or fall back to line numbers. And the function has to exist in the commit where you start.
Further reading: git log documentation, On this site: git commit –fixup plus –autosquash keeps your history clean without any editing, On this site: read a small edit in a long line with git diff –word-diff