Skip to content

Commit c381940

Browse files
author
Willi Schönborn
committed
GH-55 Added relase script
1 parent 25d29c5 commit c381940

File tree

2 files changed

+36
-11
lines changed

2 files changed

+36
-11
lines changed

.travis.yml

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
11
language: java
22

3+
sudo: false
4+
35
jdk:
4-
- openjdk8
5-
- oraclejdk8
6-
7-
dist: trusty
6+
- openjdk8
87

98
addons:
109
postgresql: "9.6"
1110

12-
# go faster on travis
13-
sudo: false
11+
cache:
12+
directories:
13+
- $HOME/.m2
1414

15-
# stop mvn install from running
16-
install: true
17-
18-
script: mvn -B -V package $( [[ "$TRAVIS_JDK_VERSION" == "oraclejdk8" ]] && echo javadoc:javadoc ) test
15+
script: ./mvnw clean verify
1916

2017
after_success:
21-
- mvn -B -V clean test jacoco:report coveralls:report
18+
- ./mvnw coveralls:report
19+
20+
notifications:
21+
email:
22+
on_failure: change

release.sh

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/bin/sh -ex
2+
3+
: ${1?"Usage: $0 <[pre]major|[pre]minor|[pre]patch|prerelease>"}
4+
5+
./mvnw scm:check-local-modification
6+
7+
current=$(git describe --abbrev=0 || echo 0.0.0)
8+
release=$(semver ${current} -i $1 --preid RC)
9+
next=$(semver ${release} -i minor)
10+
11+
git checkout -b release/${release}
12+
13+
./mvnw versions:set -D newVersion=${release}
14+
git commit -am "Release ${release}"
15+
./mvnw clean deploy scm:tag -P release -D tag=${release} -D pushChanges=false
16+
17+
./mvnw versions:set -D newVersion=${next}-SNAPSHOT
18+
git commit -am "Development ${next}-SNAPSHOT"
19+
20+
git push
21+
git push --tags
22+
23+
git checkout master
24+
git branch -D release/${release}

0 commit comments

Comments
 (0)