File tree Expand file tree Collapse file tree 3 files changed +13
-9
lines changed Expand file tree Collapse file tree 3 files changed +13
-9
lines changed Original file line number Diff line number Diff line change 3434INTERNAL_ERROR = 3
3535NOT_IN_GL_REPO = 4
3636
37- VERSION = '0.8.5 '
37+ __version__ = '0.8.6 '
3838URL = 'http://gitless.com'
3939
4040
@@ -76,7 +76,7 @@ def main():
7676 parser .add_argument (
7777 '--version' , action = 'version' , version = (
7878 'GL Version: {0}\n You can check if there\' s a new version of Gitless '
79- 'available at {1}' .format (VERSION , URL )))
79+ 'available at {1}' .format (__version__ , URL )))
8080 subparsers = parser .add_subparsers (title = 'subcommands' , dest = 'subcmd_name' )
8181 subparsers .required = True
8282
@@ -117,5 +117,5 @@ def main():
117117 pprint .err_exp (
118118 'If you want to help, see {0} for info on how to report bugs and '
119119 'include the following information:\n \n {1}\n \n {2}' .format (
120- URL , VERSION , traceback .format_exc ()))
120+ URL , __version__ , traceback .format_exc ()))
121121 return INTERNAL_ERROR
Original file line number Diff line number Diff line change @@ -3,12 +3,9 @@ import os
33
44a = Analysis (['gl.py' ],
55 pathex = [os .getcwd ()],
6- hiddenimports = ['pygit2_cffi_51591433xe8494016' ],
76 hookspath = None ,
87 runtime_hooks = None )
98
10- # this is a file pygit2 requires
11- a .datas += [('decl.h' , '../pygit2/pygit2/decl.h' , 'DATA' )]
129
1310pyz = PYZ (a .pure )
1411exe = EXE (pyz ,
Original file line number Diff line number Diff line change 22# -*- coding: utf-8 -*-
33
44
5+ import ast
6+ import re
57import sys
68
79from setuptools import setup
810
911
10- VERSION = '0.8.5'
12+ _version_re = re .compile (r'__version__\s+=\s+(.*)' )
13+
14+
15+ with open ('gitless/cli/gl.py' , 'rb' ) as f :
16+ version = str (ast .literal_eval (_version_re .search (
17+ f .read ().decode ('utf-8' )).group (1 )))
1118
1219
1320# Build helper
1825 import platform
1926
2027 rel = 'gl-v{0}-{1}-{2}' .format (
21- VERSION , platform .system ().lower (), platform .machine ())
28+ version , platform .system ().lower (), platform .machine ())
2229
2330 print ('running pyinstaller...' )
2431 pyinstaller (
5259
5360setup (
5461 name = 'gitless' ,
55- version = VERSION ,
62+ version = version ,
5663 description = 'A version control system built on top of Git' ,
5764 long_description = ld ,
5865 author = 'Santiago Perez De Rosso' ,
You can’t perform that action at this time.
0 commit comments