-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #63 from Mercateo/travis_deploy
enable travis auto deployment
- Loading branch information
Showing
3 changed files
with
56 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,25 @@ | ||
language: java | ||
install: "mvn install -DskipTests=true" | ||
script: "mvn -e clean test jacoco:report coveralls:report" | ||
jdk: | ||
- oraclejdk8 | ||
|
||
before_install: | ||
- if [ ! -z "$GPG_SECRET_KEYS" ]; then echo $GPG_SECRET_KEYS | base64 --decode | $GPG_EXECUTABLE --import; fi | ||
- if [ ! -z "$GPG_OWNERTRUST" ]; then echo $GPG_OWNERTRUST | base64 --decode | $GPG_EXECUTABLE --import-ownertrust; fi | ||
install: "mvn install -DskipTests=true" | ||
script: "mvn -e clean test jacoco:report coveralls:report" | ||
deploy: | ||
- | ||
provider: script | ||
script: .travis/deploy.sh | ||
skip_cleanup: true | ||
on: | ||
repo: Mercateo/rest-schemagen | ||
branch: master | ||
jdk: oraclejdk8 | ||
- | ||
provider: script | ||
script: .travis/deploy.sh | ||
skip_cleanup: true | ||
on: | ||
repo: Mercateo/rest-schemagen | ||
tags: true | ||
jdk: oraclejdk8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
if [ ! -z "$TRAVIS_TAG" ] | ||
then | ||
echo "on a tag -> set pom.xml <version> to $TRAVIS_TAG" | ||
mvn --settings .travis/settings.xml org.codehaus.mojo:versions-maven-plugin:2.1:set -DnewVersion=$TRAVIS_TAG 1>/dev/null 2>/dev/null | ||
else | ||
echo "not on a tag -> keep snapshot version in pom.xml" | ||
fi | ||
|
||
mvn clean deploy --settings .travis/settings.xml -DskipTests=true -B -U |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0" | ||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 | ||
http://maven.apache.org/xsd/settings-1.0.0.xsd"> | ||
<servers> | ||
<server> | ||
<!-- Maven Central Deployment --> | ||
<id>ossrh</id> | ||
<username>${env.SONATYPE_USERNAME}</username> | ||
<password>${env.SONATYPE_PASSWORD}</password> | ||
</server> | ||
</servers> | ||
<profiles> | ||
<profile> | ||
<id>ossrh</id> | ||
<activation> | ||
<activeByDefault>true</activeByDefault> | ||
</activation> | ||
<properties> | ||
<gpg.executable>${env.GPG_EXECUTABLE}</gpg.executable> | ||
<gpg.passphrase>${env.GPG_PASSPHRASE}</gpg.passphrase> | ||
</properties> | ||
</profile> | ||
</profiles> | ||
</settings> |