silly little things hun

This commit is contained in:
carlitalabbe 2020-04-02 22:14:23 -04:00
parent 9666b58ca6
commit 9e1583d7a7

16
Jenkinsfile vendored
View file

@ -1,10 +1,8 @@
def COLOR_MAP = [ def COLOR_MAP = [
'SUCCESS': 'good', 'SUCCESS': 'green',
'FAILURE': 'danger', 'FAILURE': 'red',
] ]
def getBuildUser() {
return currentBuild.rawBuild.getCause(Cause.UserIdCause).getUserId()
}
pipeline { pipeline {
agent any agent any
tools { tools {
@ -43,13 +41,13 @@ pipeline {
// Post-build actions // Post-build actions
post { post {
success{ success{
slackSend channel: '#slack-test-channel', slackSend
color: COLOR_MAP[currentBuild.currentResult], color: 'red',
message: "*${currentBuild.currentResult}:* Job ${env.JOB_NAME} build ${env.BUILD_NUMBER} \n More info at: ${env.BUILD_URL}" message: "*${currentBuild.currentResult}:* Job ${env.JOB_NAME} build ${env.BUILD_NUMBER} \n More info at: ${env.BUILD_URL}"
} }
failure{ failure{
slackSend channel: '#slack-test-channel', slackSend
color: COLOR_MAP[currentBuild.currentResult], color: 'green',
message: "*${currentBuild.currentResult}:* Job ${env.JOB_NAME} build ${env.BUILD_NUMBER} \n More info at: ${env.BUILD_URL}" message: "*${currentBuild.currentResult}:* Job ${env.JOB_NAME} build ${env.BUILD_NUMBER} \n More info at: ${env.BUILD_URL}"
} }
} }