[IMP] new version number pattern

use a pattern that can be parsed and compared as beeing between 7.0 and 8.0.
This is needed to allow successive migration scripts.
NOTE: do not backport the version_info change to trunk version

bzr revid: chs@openerp.com-20130502135404-ajnwqceovug01u5u
This commit is contained in:
Christophe Simonis
2013-05-02 15:54:04 +02:00
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -30,7 +30,7 @@ RELEASE_LEVELS_DISPLAY = {ALPHA: ALPHA,
# properly comparable using normal operarors, for example:
# (6,1,0,'beta',0) < (6,1,0,'candidate',1) < (6,1,0,'candidate',2)
# (6,1,0,'candidate',2) < (6,1,0,'final',0) < (6,1,2,'final',0)
version_info = (7, 0, 0, FINAL, 0)
version_info = (7, 'saas~1', 0, FINAL, 0)
version = '.'.join(map(str, version_info[:2])) + RELEASE_LEVELS_DISPLAY[version_info[3]] + str(version_info[4] or '')
serie = major_version = '.'.join(map(str, version_info[:2]))
+1 -1
View File
@@ -25,7 +25,7 @@
import re
component_re = re.compile(r'(\d+ | [a-z]+ | \.| -)', re.VERBOSE)
replace = {'pre':'c', 'preview':'c','-':'final-','_':'final-','rc':'c','dev':'@'}.get
replace = {'pre':'c', 'preview':'c','-':'final-','_':'final-','rc':'c','dev':'@','saas':'','~':''}.get
def _parse_version_parts(s):
for part in component_re.split(s):