hgrev (hackage): hgrev provides two modules:  Development.HgRev - Mercurial (hg) Haskell API  Development.HgRev.TH - Template Haskell splice to compile version info into Haskell code  Use $(hgRevStateTH defFormat) with Template Haskell enabled to insert the formatted version string.  hgrev requires the hg binary version 3.2 or greater is installed and available on the system. Development.HgRev.HgRev and Development.HgRev.HgState are obtained via two separate calls to hg because working directory state isn't available programmatically.  Check out the gitrev package for similar git functionality.
Keywords: bsd3|development|library|mercurial