Add Jenkins pipeline for Gradle build and notifications
This commit introduces a new Jenkinsfile configured to build the project using Gradle and archive the resulting artifacts. Additionally, it includes a stage to send build notifications to Discord with details about the build status.
This commit is contained in:
parent
ab9ec4127c
commit
4c70082f67
20
Jenkinsfile
vendored
Normal file
20
Jenkinsfile
vendored
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
pipeline {
|
||||
agent any
|
||||
stages {
|
||||
stage('Gradle') {
|
||||
steps {
|
||||
sh 'bash gradlew build'
|
||||
}
|
||||
}
|
||||
stage('Archive') {
|
||||
steps {
|
||||
archiveArtifacts artifacts: 'build/libs/', followSymlinks: false
|
||||
}
|
||||
}
|
||||
stage('discord') {
|
||||
steps {
|
||||
discordSend description: "Build: ${BUILD_NUMBER}", showChangeset: true, result: currentBuild.currentResult, title: currentBuild.fullProjectName, webhookURL: env.discordwebhook
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user