Merge branch 'jenkins' of flavien/Projet_JAVA_P2P_STRI2A into master
flavien's git/Projet_JAVA_P2P_STRI2A/pipeline/head This commit looks good
Details
flavien's git/Projet_JAVA_P2P_STRI2A/pipeline/head This commit looks good
Details
commit
0a93a130e3
@ -0,0 +1,30 @@
|
||||
pipeline {
|
||||
agent any
|
||||
|
||||
stages {
|
||||
stage('build') {
|
||||
steps {
|
||||
sh 'javac -cp "./src" -d "./bin" $(find . -iname "*.java" -type f) -Xlint:deprecation -encoding UTF8'
|
||||
sh 'echo "BUILDING CLIENT"'
|
||||
sh 'echo Main-Class: clientP2P/ClientP2P > MANIFEST.MF'
|
||||
sh 'jar -cvmf MANIFEST.MF client.jar $(find . \\( -iname "*.class" -and ! -iwholename "*/clientP2P/*.class" \\) -type f)'
|
||||
sh 'echo "BUILDING SERVER"'
|
||||
sh 'echo Main-Class: javaProjet2020/Server > MANIFEST.MF'
|
||||
sh 'jar -cvmf MANIFEST.MF server.jar $(find . \\( -iname "*.class" -and ! -iwholename "*/serverP2P/*.class" \\) -type f)'
|
||||
sh 'tar -zcvf sources.tar.gz src/'
|
||||
}
|
||||
}
|
||||
stage('run') {
|
||||
steps {
|
||||
sh 'ls'
|
||||
}
|
||||
}
|
||||
}
|
||||
post {
|
||||
success {
|
||||
archiveArtifacts artifacts: 'client.jar', fingerprint: true
|
||||
archiveArtifacts artifacts: 'server.jar', fingerprint: true
|
||||
archiveArtifacts artifacts: 'sources.tar.gz', fingerprint: true
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue