зеркало из https://github.com/mozilla/gecko-dev.git
bug 1366916 - fix version bumping from b9 -> b10. r=mtabara
MozReview-Commit-ID: EyGOg1rwr9q --HG-- extra : rebase_source : 5997fda8caa632221d5dc02feb2e01c2d72c558f
This commit is contained in:
Родитель
f2c24eea94
Коммит
f934c462b7
|
@ -10,6 +10,7 @@
|
|||
A script to increase in-tree version number after shipping a release.
|
||||
"""
|
||||
|
||||
from distutils.version import StrictVersion
|
||||
import os
|
||||
import sys
|
||||
|
||||
|
@ -158,15 +159,13 @@ class PostReleaseVersionBump(MercurialScript, BuildbotMixin,
|
|||
"""Bump version"""
|
||||
dirs = self.query_abs_dirs()
|
||||
for f in self.config["version_files"]:
|
||||
curr_version = self.get_version(dirs['abs_gecko_dir'], f["file"])
|
||||
next_version = self.config['next_version'].split('.')
|
||||
curr_version = ".".join(self.get_version(dirs['abs_gecko_dir'], f["file"]))
|
||||
next_version = self.config['next_version']
|
||||
|
||||
if next_version <= curr_version:
|
||||
if StrictVersion(next_version) <= StrictVersion(curr_version):
|
||||
self.warning("Version bumping skipped due to conflicting values")
|
||||
continue
|
||||
else:
|
||||
curr_version = ".".join(curr_version)
|
||||
next_version = ".".join(next_version)
|
||||
self.replace(os.path.join(dirs['abs_gecko_dir'], f["file"]),
|
||||
curr_version, self.config["next_version"])
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче