From 0db29475fcc818e4fa3cce14bb21009b02d1e387 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Remko=20Tron=C3=A7on?= <git@el-tramo.be>
Date: Sun, 13 Jun 2010 12:37:07 +0200
Subject: Use a less ambiguous way of tagging version builds.


diff --git a/BuildTools/SCons/Version.py b/BuildTools/SCons/Version.py
index 90bf0f8..9c690e5 100644
--- a/BuildTools/SCons/Version.py
+++ b/BuildTools/SCons/Version.py
@@ -1,9 +1,13 @@
-import subprocess, os, datetime
+import subprocess, os, datetime, re
 
 def getGitBuildVersion(project) :
   tag = git("describe --tags --exact --match \"" + project + "-*\"")
   if tag :
     return tag.rstrip()[len(project)+1:]
+  tag = git("describe --tags --match \"" + project + "-*\"")
+  m = re.match(project + "-(.*)-(.*)-(.*)", tag)
+  if m :
+    return m.group(1) + "-dev" + m.group(2)
     
 def git(cmd) :
   p = subprocess.Popen("git " + cmd, shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE, close_fds=(os.name != "nt"))
-- 
cgit v0.10.2-6-g49f6