Skip to content

Commit

Permalink
Renames maven deploy files.
Browse files Browse the repository at this point in the history
  • Loading branch information
JohannesLichtenberger committed Dec 24, 2018
1 parent 43aeb70 commit 0c03bd0
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 22 deletions.
10 changes: 5 additions & 5 deletions travis.deploy.artifacts → .travis.deploy.artifacts.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
PROJECT_VERSION=$(mvn org.apache.maven.plugins:maven-help-plugin:evaluate -Dexpression=project.version -B | grep -v '\[')
if [[ "$PROJECT_VERSION" =~ .*SNAPSHOT ]] && [[ "${TRAVIS_BRANCH}" =~ ^master$|^[0-9]+\.[0-9]+$ ]] && [[ "${TRAVIS_PULL_REQUEST}" = "false" ]];
then
mvn deploy -s travis.maven.settings.xml -DskipTests -B;
fi
PROJECT_VERSION=$(mvn org.apache.maven.plugins:maven-help-plugin:evaluate -Dexpression=project.version -B | grep -v '\[')
if [[ "$PROJECT_VERSION" =~ .*SNAPSHOT ]] && [[ "${TRAVIS_BRANCH}" =~ ^master$|^[0-9]+\.[0-9]+$ ]] && [[ "${TRAVIS_PULL_REQUEST}" = "false" ]];
then
mvn deploy -s .travis.maven.settings.xml -DskipTests -B;
fi
32 changes: 16 additions & 16 deletions travis.maven.settings.xml → .travis.maven.settings.xml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
<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">

<interactiveMode>false</interactiveMode>

<servers>
<server>
<id>sonatype-nexus-snapshots</id>
<username>${env.SONATYPE_NEXUS_USERNAME}</username>
<password>${env.SONATYPE_NEXUS_PASSWORD}</password>
</server>
</servers>

</settings>
<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">

<interactiveMode>false</interactiveMode>

<servers>
<server>
<id>sonatype-nexus-snapshots</id>
<username>${env.SONATYPE_NEXUS_USERNAME}</username>
<password>${env.SONATYPE_NEXUS_PASSWORD}</password>
</server>
</servers>

</settings>
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
- stage: deploy
name: "Deploy to Sonatype's snapshots repository"
if: type != pull_request AND env(SONATYPE_NEXUS_USERNAME) IS present
script: bash travis.deploy.artifacts.sh
script: bash .travis.deploy.artifacts.sh
notifications:
email:
on_failure: always
Expand Down

0 comments on commit 0c03bd0

Please sign in to comment.