Code fixes

This commit is contained in:
Juan Ferrer 2020-01-31 13:47:11 +01:00
parent 3a1a37aa09
commit 86c268214a
2 changed files with 20 additions and 16 deletions

View File

@ -1,6 +1,7 @@
#!/usr/bin/env groovy #!/usr/bin/env groovy
def call() { def call() {
script {
if (!env.GIT_COMMITTER_EMAIL) { if (!env.GIT_COMMITTER_EMAIL) {
env.COMMITTER_EMAIL = sh( env.COMMITTER_EMAIL = sh(
script: 'git --no-pager show -s --format="%ae"', script: 'git --no-pager show -s --format="%ae"',
@ -9,6 +10,7 @@ def call() {
} else { } else {
env.COMMITTER_EMAIL = env.GIT_COMMITTER_EMAIL; env.COMMITTER_EMAIL = env.GIT_COMMITTER_EMAIL;
} }
}
sh 'printenv' sh 'printenv'
} }

View File

@ -1,6 +1,7 @@
#!/usr/bin/env groovy #!/usr/bin/env groovy
def call() { def call() {
script {
if (!env.COMMITTER_EMAIL) return if (!env.COMMITTER_EMAIL) return
try { try {
mail( mail(
@ -12,3 +13,4 @@ def call() {
echo e.toString() echo e.toString()
} }
} }
}