|
|
|
|
|
|
|
|
-Dsource.skip=true \ |
|
|
-Dsource.skip=true \ |
|
|
-Pdeploy-sonarsource |
|
|
-Pdeploy-sonarsource |
|
|
|
|
|
|
|
|
mvn sonar:sonar \ |
|
|
|
|
|
-Dsonar.host.url=$SONAR_HOST_URL \ |
|
|
|
|
|
-Dsonar.login=$SONAR_TOKEN \ |
|
|
|
|
|
-Dsonar.branch.name=$TRAVIS_PULL_REQUEST_BRANCH \ |
|
|
|
|
|
-Dsonar.branch.target=$TRAVIS_BRANCH |
|
|
|
|
|
|
|
|
|
|
|
# second analysis to decorate GitHub pull request |
|
|
|
|
|
|
|
|
# analysis to decorate GitHub pull request |
|
|
# (need support of standard analysis mode in GH plugin) |
|
|
# (need support of standard analysis mode in GH plugin) |
|
|
mvn sonar:sonar \ |
|
|
mvn sonar:sonar \ |
|
|
-Dsonar.host.url=$SONAR_HOST_URL \ |
|
|
-Dsonar.host.url=$SONAR_HOST_URL \ |
|
|
|
|
|
|
|
|
-Dsonar.github.repository=$TRAVIS_REPO_SLUG \ |
|
|
-Dsonar.github.repository=$TRAVIS_REPO_SLUG \ |
|
|
-Dsonar.github.oauth=$GITHUB_TOKEN |
|
|
-Dsonar.github.oauth=$GITHUB_TOKEN |
|
|
|
|
|
|
|
|
|
|
|
if [ "$TRAVIS_BRANCH" == "master" ]; then |
|
|
|
|
|
# analysis of short-living branch based on another short-living branch |
|
|
|
|
|
# is currently not supported |
|
|
|
|
|
mvn sonar:sonar \ |
|
|
|
|
|
-Dsonar.host.url=$SONAR_HOST_URL \ |
|
|
|
|
|
-Dsonar.login=$SONAR_TOKEN \ |
|
|
|
|
|
-Dsonar.branch.name=$TRAVIS_PULL_REQUEST_BRANCH \ |
|
|
|
|
|
-Dsonar.branch.target=$TRAVIS_BRANCH |
|
|
|
|
|
fi |
|
|
else |
|
|
else |
|
|
echo 'Build feature branch or external pull request' |
|
|
echo 'Build feature branch or external pull request' |
|
|
|
|
|
|