mirror of
https://github.com/GeyserMC/MCProtocolLib.git
synced 2024-11-14 19:34:58 -05:00
78 lines
No EOL
2.2 KiB
Groovy
78 lines
No EOL
2.2 KiB
Groovy
pipeline {
|
|
agent any
|
|
tools {
|
|
maven 'Maven 3'
|
|
jdk 'Java 8'
|
|
}
|
|
options {
|
|
buildDiscarder(logRotator(artifactNumToKeepStr: '20'))
|
|
}
|
|
stages {
|
|
stage ('Build') {
|
|
steps {
|
|
sh 'mvn clean package'
|
|
}
|
|
post {
|
|
success {
|
|
archiveArtifacts artifacts: 'target/*.jar', excludes: 'target/*-sources.jar', fingerprint: true
|
|
}
|
|
}
|
|
}
|
|
|
|
stage ('Deploy') {
|
|
when {
|
|
branch "master"
|
|
}
|
|
pipeline {
|
|
agent any
|
|
tools {
|
|
maven 'Maven 3'
|
|
jdk 'Java 8'
|
|
}
|
|
options {
|
|
buildDiscarder(logRotator(artifactNumToKeepStr: '20'))
|
|
}
|
|
stages {
|
|
stage ('Build') {
|
|
steps {
|
|
sh 'mvn clean package'
|
|
}
|
|
post {
|
|
success {
|
|
archiveArtifacts artifacts: 'target/*.jar', excludes: 'target/*-sources.jar', fingerprint: true
|
|
}
|
|
}
|
|
}
|
|
|
|
stage ('Deploy') {
|
|
when {
|
|
branch "master"
|
|
}
|
|
|
|
steps {
|
|
rtMavenDeployer(
|
|
id: "maven-deployer",
|
|
serverId: "opencollab-artifactory",
|
|
releaseRepo: "maven-releases",
|
|
snapshotRepo: "maven-snapshots"
|
|
)
|
|
rtMavenResolver(
|
|
id: "maven-resolver",
|
|
serverId: "opencollab-artifactory",
|
|
releaseRepo: "maven-deploy-release",
|
|
snapshotRepo: "maven-deploy-snapshot"
|
|
)
|
|
rtMavenRun(
|
|
pom: 'pom.xml',
|
|
goals: 'javadoc:javadoc javadoc:jar source:jar install -DskipTests',
|
|
deployerId: "maven-deployer",
|
|
resolverId: "maven-resolver"
|
|
)
|
|
rtPublishBuildInfo(
|
|
serverId: "opencollab-artifactory"
|
|
)
|
|
step([$class: 'JavadocArchiver', javadocDir: 'target/site/apidocs', keepAll: false])
|
|
}
|
|
}
|
|
}
|
|
} |