Add git id to version string - pee - Pee a password manager;Pee - because you have to...
 (HTM) git clone git://vernunftzentrum.de/pee.git
 (DIR) Log
 (DIR) Files
 (DIR) Refs
 (DIR) LICENSE
       ---
 (DIR) commit f2c58eb28c7978cb9e7795b0f5d7e9a15a9888cd
 (DIR) parent 499d93e6d0b18bab4a07665685a85c430fff29ec
 (HTM) Author: Christian Kellermann <ckeen@pestilenz.org>
       Date:   Tue, 19 Apr 2016 16:17:31 +0200
       
       Add git id to version string
       
       Diffstat:
         compile.sh                          |       6 +++++-
         pee.scm                             |       2 +-
         program-meta.scm                    |       1 +
       
       3 files changed, 7 insertions(+), 2 deletions(-)
       ---
 (DIR) diff --git a/compile.sh b/compile.sh
       @@ -1,6 +1,9 @@
        #!/bin/sh
        set -e
        
       +echo -n '(define-constant commit-id "'\
       +     $(git show -q | grep ^commit| awk '{print $2 }') '")' > hash
       +
        chicken-install -r blob-utils >/dev/null || echo Fetching blob-utils has failed.
        chicken-install -r check-errors >/dev/null || echo Fetching check-errors has failed.
        chicken-install -r foreigners >/dev/null || echo Fetching foreigners has failed.
       @@ -27,5 +30,6 @@ csc -static *o ./tweetnacl/tweetnacl.impl.o  -o pee
        
        strip ./pee
        
       -rm -r matchable blob-utils check-errors foreigners getopt-long string-utils stty tweetnacl
       +rm -r matchable blob-utils check-errors foreigners getopt-long string-utils stty tweetnacl hash
        rm *.o *.import.*
       +
 (DIR) diff --git a/pee.scm b/pee.scm
       @@ -266,7 +266,7 @@
             (value #f))))
        
        (define (banner)
       -  (printf "~a Version ~a -- ~a~%" program-name-string program-version program-description))
       +  (printf "~a Version ~a (~a) -- ~a~%" program-name-string program-version commit-id program-description))
        
        (define (do-add db-name db p e)
          (when (alist-ref e db equal?)
 (DIR) diff --git a/program-meta.scm b/program-meta.scm
       @@ -1,3 +1,4 @@
        (define-constant program-name-string "pee")
        (define-constant program-version "0.2")
        (define-constant program-description "A password manager for the command line.")
       +(include "hash")