dont use bzr revno in setup.py
This commit is contained in:
parent
8f4c9f8eed
commit
fbc26c4e16
1 changed files with 7 additions and 3 deletions
10
setup.py
10
setup.py
|
@ -8,9 +8,13 @@ except:
|
|||
|
||||
def get_bzr_version():
|
||||
import os
|
||||
rev = int(os.popen('bzr revno').read())
|
||||
if rev:
|
||||
return u'%s' % rev
|
||||
info = os.path.join(os.path.dirname(__file__), '.bzr/branch/last-revision')
|
||||
if os.path.exists(info):
|
||||
f = open(info)
|
||||
rev = int(f.read().split()[0])
|
||||
f.close()
|
||||
if rev:
|
||||
return u'%s' % rev
|
||||
return u'unknown'
|
||||
|
||||
setup(
|
||||
|
|
Loading…
Reference in a new issue