Gitmap: map filenames to last commit-info

I wrote this as part of a feature in Hugo, the static site generator, to use the last updated timestamp from the Git repo as the page modification date. But then I thought it might be interesting to others (and myself), so I pulled the code into its own repo.

A fairly fast way to create a map from all the filenames to info objects for a given revision of a Git repo.

This library uses os/exec to talk to Git. There are faster ways to do this by using some Go Git-lib or C bindings, but that adds dependencies I really don’t want or need.

If some git log kung fu master out there have suggestions for improvements, please open an issue or a PR.

bep

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.