diff --git a/src/common/defs.py b/src/common/defs.py
index c98fc3c5c5e126f73b0083f7c0dbd19813ceb0fd..885de925d6a34af7a598be226097b213c58c7947 100644
--- a/src/common/defs.py
+++ b/src/common/defs.py
@@ -30,10 +30,9 @@ localedir = '../po'
 version = '0.14.1.1'
 import subprocess
 try:
-    node = subprocess.Popen('hg tip --template {node}', shell=True,
+    node = subprocess.Popen('hg tip --template "{node|short}"', shell=True,
         stdout=subprocess.PIPE).communicate()[0]
-    hgversion = node[:12]
-    version += '-' + hgversion
+    version += '-' + node
 except Exception:
     pass