Flywheel/Jenkinsfile
Jozufozu d5963455dc No secrets here
- Remove withCredentials block in Build
2025-01-26 15:30:08 -08:00

46 lines
1 KiB
Groovy

#!/usr/bin/env groovy
pipeline {
agent any
tools {
jdk "jdk-17.0.1"
}
stages {
stage('Setup') {
steps {
echo 'Setup Project'
sh 'chmod +x gradlew'
sh './gradlew clean'
}
}
stage('Build') {
steps {
echo 'Building project.'
sh './gradlew build publish --stacktrace --warn'
}
}
}
post {
always {
archiveArtifacts artifacts: '**/build/libs/*.jar', fingerprint: true
withCredentials([
string(credentialsId: 'discord_webhook_url', variable: 'DISCORD_URL')
]) {
echo 'Notifying Discord..'
discordSend description: "Build: #${currentBuild.number}", link: env.BUILD_URL, result: currentBuild.currentResult, title: env.JOB_NAME, webhookURL: env.DISCORD_URL, showChangeset: true, enableArtifactsList: true
}
}
}
}