Added release step to pom
This commit is contained in:
parent
750bb24f55
commit
15e884db95
2 changed files with 25 additions and 13 deletions
12
Jenkinsfile
vendored
12
Jenkinsfile
vendored
|
|
@ -1,5 +1,6 @@
|
|||
#!groovy
|
||||
// Jenkinsfile (Pipeline Script)
|
||||
withMaven(jdk: "jdk8", maven: "m3.5", mavenLocalRepo: ".repository", mavenSettingsConfig: "639c4560-87b7-4502-bb3d-2c44845cd2b5") {
|
||||
node {
|
||||
// Configure environment
|
||||
env.REPO_URL = "repo.koc.se/zutil-java.git" //scm.getUserRemoteConfigs()[0].getUrl()
|
||||
|
|
@ -9,8 +10,6 @@ node {
|
|||
git url: "https://" + env.REPO_URL
|
||||
}
|
||||
|
||||
withMaven(jdk: "jdk8", maven: "m3.5", mavenLocalRepo: ".repository", mavenSettingsConfig: "639c4560-87b7-4502-bb3d-2c44845cd2b5") {
|
||||
|
||||
stage('Build') {
|
||||
sh 'mvn clean compile'
|
||||
}
|
||||
|
|
@ -34,4 +33,13 @@ node {
|
|||
sh 'mvn -DskipStatic -DskipTests deploy'
|
||||
}
|
||||
}
|
||||
|
||||
stage('Release') {
|
||||
timeout(time: 1, unit: 'HOURS') {
|
||||
input message: 'Deploy?', submitter: 'ziver'
|
||||
node {
|
||||
sh 'mvn --batch-mode -DskipStatic -DskipTests release:prepare release:perform'
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
10
pom.xml
10
pom.xml
|
|
@ -28,7 +28,7 @@
|
|||
|
||||
<scm>
|
||||
<connection>scm:git:https://github.com/Ziver/zutil.git</connection>
|
||||
<developerConnection>scm:git:https://github.com/Ziver/zutil.git</developerConnection>
|
||||
<developerConnection>scm:git:https://repo.koc.se/zutil-java.git</developerConnection>
|
||||
<url>https://github.com/Ziver/zutil</url>
|
||||
</scm>
|
||||
|
||||
|
|
@ -111,6 +111,8 @@
|
|||
<target>${java.version}</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
|
||||
<!-- Plugins needed for deployment -->
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-source-plugin</artifactId>
|
||||
|
|
@ -124,8 +126,6 @@
|
|||
</execution>
|
||||
</executions>
|
||||
</plugin>
|
||||
|
||||
<!-- Plugins needed for deployment -->
|
||||
<plugin>
|
||||
<groupId>org.apache.maven.plugins</groupId>
|
||||
<artifactId>maven-javadoc-plugin</artifactId>
|
||||
|
|
@ -167,6 +167,10 @@
|
|||
<autoReleaseAfterClose>true</autoReleaseAfterClose>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
<artifactId>maven-release-plugin</artifactId>
|
||||
<version>2.5.3</version>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue