Skip to content
Snippets Groups Projects
Commit 8af6bd2a authored by Yann Leboulanger's avatar Yann Leboulanger
Browse files

mercurial python module is not installed in site-packages under windows. use...

mercurial python module is not installed in site-packages under windows. use hg binary instead to get current revision
parent f4e0992e
No related branches found
No related tags found
No related merge requests found
......@@ -30,11 +30,9 @@ localedir = '../po'
version = '0.13.90.1'
import subprocess
try:
from mercurial import ui, hg
from mercurial.context import hex as hex_
repo = hg.repository(ui.ui(), '..')
node = repo['tip'].node()
hgversion = hex_(node)[:12]
node = subprocess.Popen('hg tip --template {node}', shell=True,
stdout=subprocess.PIPE).communicate()[0]
hgversion = node[:12]
version += '-' + hgversion
except Exception:
pass
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment