Pull in a versioning fix from openstack-common.
Fixes bug 1059634. Related to I6cff4ee7f6c1dc970397b66fd2d15fa22b0a63a3 Change-Id: I4c8daa8bf4a57849bd8d1e512a388d982f79b7d5
This commit is contained in:
parent
910852a237
commit
68253587f0
@ -136,15 +136,16 @@ def _get_git_next_version_suffix(branch_name):
|
||||
_run_shell_command("git fetch origin +refs/meta/*:refs/remotes/meta/*")
|
||||
milestone_cmd = "git show meta/openstack/release:%s" % branch_name
|
||||
milestonever = _run_shell_command(milestone_cmd)
|
||||
if not milestonever:
|
||||
milestonever = ""
|
||||
if milestonever:
|
||||
first_half = "%s~%s" % (milestonever, datestamp)
|
||||
else:
|
||||
first_half = datestamp
|
||||
post_version = _get_git_post_version()
|
||||
# post version should look like:
|
||||
# 0.1.1.4.gcc9e28a
|
||||
# where the bit after the last . is the short sha, and the bit between
|
||||
# the last and second to last is the revno count
|
||||
(revno, sha) = post_version.split(".")[-2:]
|
||||
first_half = "%s~%s" % (milestonever, datestamp)
|
||||
second_half = "%s%s.%s" % (revno_prefix, revno, sha)
|
||||
return ".".join((first_half, second_half))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user