Skip to content

Commit

Permalink
Correct version release tag in Makefile and Sphinx
Browse files Browse the repository at this point in the history
  • Loading branch information
xdelaruelle committed Nov 1, 2017
1 parent a5d7f60 commit 3c77ba2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ doc: version.inc
# build version.inc shared definitions from git repository info
ifeq ($(wildcard .git) $(wildcard version.inc.in),.git version.inc.in)
GIT_CURRENT_TAG := $(shell git describe --tags --abbrev=0)
GIT_CURRENT_DESC := $(shell git describe --tags --dirty=-wip)
GIT_CURRENT_DESC := $(shell git describe --tags)
GIT_CURRENT_BRANCH := $(shell git rev-parse --abbrev-ref HEAD)

MODULES_RELEASE := $(subst v,,$(GIT_CURRENT_TAG))
Expand Down
4 changes: 2 additions & 2 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def get_version_release_from_git():
DEVNULL = open(os.devnull, 'w')
pipe = Popen('git describe --tags --abbrev=0', stdout=PIPE, stderr=DEVNULL, shell=True)
git_current_tag = pipe.stdout.read()
pipe = Popen('git describe --tags --dirty=-wip', stdout=PIPE, stderr=DEVNULL, shell=True)
pipe = Popen('git describe --tags', stdout=PIPE, stderr=DEVNULL, shell=True)
git_current_desc = pipe.stdout.read()
pipe = Popen('git rev-parse --abbrev-ref HEAD', stdout=PIPE, stderr=DEVNULL, shell=True)
git_current_branch = pipe.stdout.read()
Expand All @@ -72,7 +72,7 @@ def get_version_release_from_git():
return version, ''
else:
branch = git_current_branch.rstrip()
tags = git_current_desc.lstrip(git_current_tag).rstrip()
tags = git_current_desc.lstrip(git_current_tag + '-').rstrip()
if branch == 'master':
return version, version + '+' + tags
else:
Expand Down

0 comments on commit 3c77ba2

Please sign in to comment.