|
@@ -18,8 +18,15 @@ const getGitBranch = () => {
|
|
|
}
|
|
|
|
|
|
const extractVersion = (branch) => {
|
|
|
+ let numberBranch = branch
|
|
|
+ if (numberBranch.indexOf('/')) {
|
|
|
+ numberBranch = numberBranch.split('/')[1]
|
|
|
+ }
|
|
|
+ if (numberBranch.indexOf('_')) {
|
|
|
+ numberBranch = numberBranch.split('_')[0]
|
|
|
+ }
|
|
|
const versionRegex = /(v.*?)$/
|
|
|
- const matches = branch.match(versionRegex)
|
|
|
+ const matches = numberBranch.match(versionRegex)
|
|
|
return matches ? matches[0] : ''
|
|
|
}
|
|
|
|