Skip to content
This repository was archived by the owner on Feb 22, 2018. It is now read-only.

Commit 04374c3

Browse files
committed
fix(travis): BUILD_LEADER is not available in build.sh
Replace with check that TRAVIS_JOB_NUMBER ends at .1. Do not publish docs on pull requests. Closes #1362
1 parent 773238b commit 04374c3

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

scripts/travis/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ fi
128128
echo '-------------------------'
129129
echo '-- DOCS: Generate Docs --'
130130
echo '-------------------------'
131-
if [[ $BUILD_LEADER == "YES" ]]; then
131+
if [[ ${TRAVIS_JOB_NUMBER:(-2)} == ".1" ]]; then
132132
echo $NGDART_SCRIPT_DIR/generate-documentation.sh;
133133
$NGDART_SCRIPT_DIR/generate-documentation.sh;
134134
fi

scripts/travis/publish-docs.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ echo Current branch is: $TRAVIS_BRANCH
1111
echo Test result is: $TRAVIS_TEST_RESULT
1212

1313
if [ "$TRAVIS_REPO_SLUG" = "angular/angular.dart" ]; then
14-
if [ $TRAVIS_TEST_RESULT -eq 0 ] && [ "$TRAVIS_BRANCH" = "master" ]; then
14+
if [ $TRAVIS_TEST_RESULT -eq 0 ] && [ "$TRAVIS_BRANCH" = "master" ] && [ "$TRAVIS_PULL_REQUEST" = "false" ]; then
1515
echo "Gettting current docs from docs.angulardart.org repo on Github"
1616
rm -Rf docs.angulardart.org
1717
git clone https://github.com/angular/docs.angulardart.org.git

0 commit comments

Comments
 (0)