fix(jenkins): do not trigger emissary-firmware with dirty tag
arcad/emissary/pipeline/head This commit is unstable
Details
arcad/emissary/pipeline/head This commit is unstable
Details
This commit is contained in:
parent
06b1235707
commit
7ee4344adc
|
@ -15,9 +15,9 @@ pipeline {
|
||||||
script {
|
script {
|
||||||
withCredentials([
|
withCredentials([
|
||||||
usernamePassword([
|
usernamePassword([
|
||||||
credentialsId: 'forge-jenkins',
|
credentialsId: 'forge-jenkins',
|
||||||
usernameVariable: 'GIT_USERNAME',
|
usernameVariable: 'GIT_USERNAME',
|
||||||
passwordVariable: 'GIT_PASSWORD'
|
passwordVariable: 'GIT_PASSWORD'
|
||||||
])
|
])
|
||||||
]) {
|
]) {
|
||||||
sh '''
|
sh '''
|
||||||
|
@ -43,20 +43,24 @@ pipeline {
|
||||||
script {
|
script {
|
||||||
withCredentials([
|
withCredentials([
|
||||||
usernamePassword([
|
usernamePassword([
|
||||||
credentialsId: 'forge-jenkins',
|
credentialsId: 'forge-jenkins',
|
||||||
usernameVariable: 'GITEA_RELEASE_USERNAME',
|
usernameVariable: 'GITEA_RELEASE_USERNAME',
|
||||||
passwordVariable: 'GITEA_RELEASE_PASSWORD'
|
passwordVariable: 'GITEA_RELEASE_PASSWORD'
|
||||||
])
|
])
|
||||||
]) {
|
]) {
|
||||||
sh 'make gitea-release'
|
sh 'make gitea-release'
|
||||||
}
|
}
|
||||||
def currentVersion = sh(returnStdout: true, script: 'make full-version').trim()
|
def currentVersion = sh(returnStdout: true, script: 'make full-version').trim()
|
||||||
build(
|
if (currentVersion.endsWith('-dirty')) {
|
||||||
job: "../emissary-firmware/${env.GIT_BRANCH}",
|
unstable('Could not trigger emissary-firmware build, dirty version !')
|
||||||
parameters: [
|
} else {
|
||||||
[$class: 'StringParameterValue', name: 'emissaryRelease', value: currentVersion]
|
build(
|
||||||
]
|
job: "../emissary-firmware/${env.GIT_BRANCH}",
|
||||||
)
|
parameters: [
|
||||||
|
[$class: 'StringParameterValue', name: 'emissaryRelease', value: currentVersion]
|
||||||
|
]
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue