X-Git-Url: https://git.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/blobdiff_plain/e3ac0d70956f5b5fee633f7cbf4b3b8616e4f06c..3c528f5fda84614c430d195624b3e8e18f954a5a:/tools/mkversion.pl?ds=inline

diff --git a/tools/mkversion.pl b/tools/mkversion.pl
index de394a85..2755b3b9 100644
--- a/tools/mkversion.pl
+++ b/tools/mkversion.pl
@@ -5,20 +5,28 @@
 # -- Henryk Plötz <henryk@ploetzli.ch> 2009-09-28
 # Modified april 2014 because of the move to github. 
 # --- Martin Holst Swende <martin@swende.se>
+# Modified january 2016 to work with Travis-CI
+# --- iceman <iceman@iuse.se>
 
-
-# Clear environment locale so that svn will not use localized strings
+# Clear environment locale so that git will not use localized strings
 $ENV{'LC_ALL'} = "C";
 $ENV{'LANG'} = "C";
 
+my $githistory = `git fetch --all`;
 my $gitversion = `git describe --dirty`;
 my $gitbranch = `git rev-parse --abbrev-ref HEAD`;
 my $clean = 2;
-my @compiletime = gmtime();
+my @compiletime = localtime();
+
+my $fullgitinfo = 'iceman';
 
-my $fullgitinfo= $gitbranch . '/'.$gitversion;
+if ( defined $gitbranch and defined $gitversion ) {
+	$fullgitinfo =  $fullgitinfo.'/'. $gitbranch . '/' . $gitversion;
+} else {
+	$fullgitinfo =  $fullgitinfo.'/master/release-build (no_git)';
+}
 
-$fullgitinfo=~ s/(\s)//g;
+$fullgitinfo =~ s/(\s)//g;
 
 # Crop so it fits within 50 characters
 $fullgitinfo =~ s/.{50}\K.*//s;