Skip to content

Commit 422ba83

Browse files
authored
Update Jenkinsfile
1 parent 5b55050 commit 422ba83

File tree

1 file changed

+7
-14
lines changed

1 file changed

+7
-14
lines changed

Jenkinsfile

Lines changed: 7 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,19 @@
1-
pipeline {
1+
pipeline{
22
agent any
3-
4-
tools {
5-
maven "MAVEN"
6-
}
7-
8-
stages {
9-
stage('Build') {
10-
steps {
3+
stages{
4+
stage("build"){
5+
steps{
116
bat "mvn clean package"
127
}
138
}
14-
15-
stage('Run') {
16-
steps {
9+
stage("run"){
10+
steps{
1711
bat "java -cp target/my-app-1.0-SNAPSHOT.jar com.mycompany.app.App"
1812
}
1913
}
2014
}
21-
2215
post {
23-
always {
16+
success{
2417
archiveArtifacts artifacts: "**/target/*.jar"
2518
}
2619
}

0 commit comments

Comments
 (0)