Skip to content

Commit

Permalink
Merge branch 'release/v0.2.3'
Browse files Browse the repository at this point in the history
fixed version detection when installed as module
  • Loading branch information
madmickstar committed Jan 13, 2017
2 parents 7681610 + 04842e7 commit 983ce67
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion restorething/_version.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@


__version__ = '0.2.2'
__version__ = '0.2.3'
3 changes: 2 additions & 1 deletion restorething/rttools.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ def process_working_dir():


def get_version(path):
with open(path, encoding='utf-8') as f:
fullpath = os.path.join(os.path.dirname(sys.argv[0]), path)
with open(fullpath, encoding='utf-8') as f:
version_file = f.read()
regex = r"^__version__ = ['\"]([^'\"]*)['\"]"
version_match = re.search(regex, version_file, re.M)
Expand Down

0 comments on commit 983ce67

Please sign in to comment.