When editing a file managed by Git,
vc-annotate shows the output of
git blame. As Git usually does, revisions are identified by a short commit id.
The short commit id is abbreviated to be one character longer than in the output of every other command. This breaks workflows where I use the annotate buffer to navigate to a commit, copy the revision (which is an abbreviated commit id), and search this abbreviated commit id elsewhere (
git log --oneline, Magit control buffer,
git rebase -i commit list, …). I need to remove the last character from the commit id.
If I can't convince Git itself to use the same short commit length for
git blame as for other commands, how can I make
vc-annotate strip the last character of commit ids?
A quick look at the vc code doesn't reveal an obvious way to run a hook after a specific command for a specific version control system.