I've been considering adding commit hash info to some documentation made using the
Quickbook/Boostbook/Docbook/b2/bjam toolchain
Using git command line git log or ls-remote I can show the necessary hex digit string:
commit 5609fa86e37e1b0eae6466065ba6c8eb3ac0ab2f (HEAD -> refactor1)
(It would be useful to have the local commit (rather than remote) so that the generated
documentation including this has can be pushed up to remote).
Paul@hetpD MINGW64 /i/boost/libs/quan/doc (refactor1)
$ git log -n1 HEAD > commit.txt
That contains
commit 5609fa86e37e1b0eae6466065ba6c8eb3ac0ab2f
Author: pabristow