mirror of
https://github.com/Jozufozu/Flywheel.git
synced 2025-01-30 23:04:57 +01:00
6a32b30245
- Add Jenkinsfile to configure createmod CI - Move from dev.engine_room to dev.engine-room publication group
54 lines
1.4 KiB
Groovy
54 lines
1.4 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 {
|
|
|
|
withCredentials([
|
|
file(credentialsId: 'build_secrets', variable: 'ORG_GRADLE_PROJECT_secretFile'),
|
|
//file(credentialsId: 'java_keystore', variable: 'ORG_GRADLE_PROJECT_keyStore'),
|
|
file(credentialsId: 'gpg_key', variable: 'ORG_GRADLE_PROJECT_pgpKeyRing')
|
|
]) {
|
|
|
|
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
|
|
}
|
|
}
|
|
}
|
|
}
|