POSIX-style output. Still works.
git annotate is the POSIX-flavoured sibling of git blame — same machinery, different output format kept around for tools that expected the classic annotate shape (CVS/SVN era).
Think blame in a different shirt. Identical history walk, identical rename/copy detection, only the line prefix layout differs.
git annotate [-b] [--root] [--show-stats] [-L <range>]
[-l] [-t] [-S <revs-file>] [-M] [-C] [-C] [-C]
[--since=<date>] [<rev>] [--] <file>| Flag | What it does |
|---|---|
`-l` | Show long (full 40-char) commit SHA, not the abbreviated form. |
`-t` | Show raw timestamp (epoch seconds + tz) instead of pretty date. |
`-S <revs-file>` | Use the given file as a list of revisions to walk — replaces history traversal with a curated set. |
`-M` | Detect moved/copied lines within the same file across renames. |
`-C` | Detect lines copied from other files in the same commit; repeat (-C -C) to widen the search. |
`-L <start>,<end>` | Annotate only the given line range — same syntax as blame. |
`--show-stats` | Print stats about the blame run (commits inspected, etc.). |
annotate format.git annotate path/to/file.pygit annotate -l -t src/main.cgit annotate -L 40,80 README.mdgit annotate -M -C -C lib/util.gogit blame for human reading — it's the actively-maintained UX.annotate only when a downstream tool requires its format.-l when piping to scripts — short SHAs are ambiguous in big repos.git blame exactly.-C -C -C (repeated) can be slow on large histories.Hit each option, then Check answers. Score is recorded; Next is always open.