FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

setup.py: restore the version discovery hack · pythonthings/python-gitlab@9966616 · GitHub

Repository navigation

Commit 9966616

Browse files
Gauvain Pocentek
committed
setup.py: restore the version discovery hack
1 parent e12abf1 commit 9966616

2 files changed

Lines changed: 8 additions & 4 deletions

File tree

‎ChangeLog‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
Version 0.9.1
2+
3+
* Fix the setup.py script
4+
15
Version 0.9
26

37
* Implement argparse libray for parsing argument on CLI

‎setup.py‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@
44
from setuptools import setup
55
from setuptools import find_packages
66

7-
import gitlab
8-
97

108
def get_version():
11-
12-
return gitlab.__version__
9+
with open('gitlab/__init__.py') as f:
10+
for line in f:
11+
if line.startswith('__version__'):
12+
return eval(line.split('=')[-1])
1313

1414

1515
setup(name='python-gitlab',

0 commit comments

Comments
 (0)

Back | FazBrowse Home | New Git URL