aboutsummaryrefslogtreecommitdiffstats
path: root/travis.sh
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@sonarsource.com>2015-11-30 09:21:35 +0100
committerSimon Brandhof <simon.brandhof@sonarsource.com>2015-11-30 09:21:35 +0100
commit4f07f62c70a0694ba7a7aa62980076223b909238 (patch)
tree9c5f34ae588bbf3acb0a9d6a5f7a3d1c195fd746 /travis.sh
parent12cd5e914608de3ef94b591fb6971ec4206bac99 (diff)
downloadsonarqube-4f07f62c70a0694ba7a7aa62980076223b909238.tar.gz
sonarqube-4f07f62c70a0694ba7a7aa62980076223b909238.zip
Analyze naming convention to travis.sh env variable GITHUB_TOKEN
Diffstat (limited to 'travis.sh')
-rwxr-xr-xtravis.sh8
1 files changed, 4 insertions, 4 deletions
diff --git a/travis.sh b/travis.sh
index 91607fe1938..d3972b45461 100755
--- a/travis.sh
+++ b/travis.sh
@@ -16,11 +16,11 @@ function strongEcho {
case "$TARGET" in
CI)
- if [ "$TRAVIS_PULL_REQUEST" != "false" ] && [ -n "$SONAR_GITHUB_OAUTH" ]; then
+ if [ "$TRAVIS_PULL_REQUEST" != "false" ] && [ -n "$GITHUB_TOKEN" ]; then
# For security reasons environment variables are not available on the pull requests
# coming from outside repositories
# http://docs.travis-ci.com/user/pull-requests/#Security-Restrictions-when-testing-Pull-Requests
- # That's why the analysis does not need to be executed if the variable SONAR_GITHUB_OAUTH is not defined.
+ # That's why the analysis does not need to be executed if the variable GITHUB_TOKEN is not defined.
strongEcho 'Build and analyze pull request'
# this pull request must be built and analyzed (without upload of report)
@@ -34,7 +34,7 @@ CI)
-Dsonar.analysis.mode=issues \
-Dsonar.github.pullRequest=$TRAVIS_PULL_REQUEST \
-Dsonar.github.repository=$TRAVIS_REPO_SLUG \
- -Dsonar.github.oauth=$SONAR_GITHUB_OAUTH \
+ -Dsonar.github.oauth=$GITHUB_TOKEN \
-Dsonar.host.url=$SONAR_HOST_URL \
-Dsonar.login=$SONAR_LOGIN \
-Dsonar.password=$SONAR_PASSWORD
@@ -76,7 +76,7 @@ WEB)
;;
IT)
- if [ "$IT_CATEGORY" == "Plugins" ] && [ -n "$SONAR_GITHUB_OAUTH" ]; then
+ if [ "$IT_CATEGORY" == "Plugins" ] && [ -n "$GITHUB_TOKEN" ]; then
echo "This job is ignored as it needs to access a private GitHub repository"
else
installTravisTools