|
@@ -53,11 +53,15 @@ class BuilderSettings(object):
|
|
def stable_branch_pattern(self):
|
|
def stable_branch_pattern(self):
|
|
""" Only upload the package the branch name is like a tag
|
|
""" Only upload the package the branch name is like a tag
|
|
"""
|
|
"""
|
|
- return os.getenv("CONAN_STABLE_BRANCH_PATTERN", r"\d+\.\d+\.\d+")
|
|
|
|
|
|
+ return os.getenv("CONAN_STABLE_BRANCH_PATTERN", r"v(\d+\.\d+)")
|
|
|
|
|
|
@property
|
|
@property
|
|
def version(self):
|
|
def version(self):
|
|
- return self.branch if re.match(self.stable_branch_pattern, self.branch) else "latest"
|
|
|
|
|
|
+ regex = re.compile(self.stable_branch_pattern)
|
|
|
|
+ match = regex.match(self.branch)
|
|
|
|
+ if match:
|
|
|
|
+ return match.group(1)
|
|
|
|
+ return "latest"
|
|
|
|
|
|
@property
|
|
@property
|
|
def reference(self):
|
|
def reference(self):
|