Jenkinsfile fixes
gitea/salix/dev This commit looks good
Details
gitea/salix/dev This commit looks good
Details
This commit is contained in:
parent
acc324c081
commit
9108e0af52
|
@ -17,10 +17,15 @@ pipeline {
|
|||
steps {
|
||||
script {
|
||||
env.COMPOSE_PROJECT_NAME = "${env.PROJECT_NAME}-${env.BRANCH_NAME}"
|
||||
env.GIT_COMMITTER_EMAIL = sh(
|
||||
|
||||
if (!env.GIT_COMMITTER_EMAIL) {
|
||||
env.COMMITTER_EMAIL = sh(
|
||||
script: 'git --no-pager show -s --format="%ae"',
|
||||
returnStdout: true
|
||||
).trim()
|
||||
} else {
|
||||
env.COMMITTER_EMAIL = env.GIT_COMMITTER_EMAIL;
|
||||
}
|
||||
|
||||
switch (env.BRANCH_NAME) {
|
||||
case 'master':
|
||||
|
@ -39,7 +44,7 @@ pipeline {
|
|||
break
|
||||
}
|
||||
}
|
||||
echo "Committer: ${env.GIT_COMMITTER_EMAIL}"
|
||||
sh 'printenv'
|
||||
}
|
||||
}
|
||||
stage('Install') {
|
||||
|
@ -143,7 +148,7 @@ pipeline {
|
|||
}
|
||||
}
|
||||
|
||||
if (!env.GIT_COMMITTER_EMAIL) return
|
||||
if (!env.COMMITTER_EMAIL) return
|
||||
try {
|
||||
mail(
|
||||
to: env.GIT_COMMITTER_EMAIL,
|
||||
|
|
Loading…
Reference in New Issue