Skip to content

Commit d9d8a81

Browse files
committed
Fix documentation script
1 parent 4f6d17c commit d9d8a81

File tree

1 file changed

+17
-18
lines changed

1 file changed

+17
-18
lines changed

.travis.yml

Lines changed: 17 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -15,28 +15,27 @@ script:
1515
- cargo test --verbose --features iron-handlers
1616

1717
after_success: |
18-
set -e
19-
[ $TRAVIS_BRANCH = master ]
20-
[ $TRAVIS_PULL_REQUEST = false ]
21-
[ $TRAVIS_RUST_VERSION = stable ]
18+
if [ "$TRAVIS_BRANCH" = master -a "$TRAVIS_PULL_REQUEST" = false -a "$TRAVIS_RUST_VERSION" = stable ]; then
19+
set -e
2220
23-
cargo doc --features iron-handlers
21+
cargo doc --features iron-handlers
2422
25-
mkdir -p ~/.ssh
26-
openssl aes-256-cbc -K $encrypted_7258158212d8_key -iv $encrypted_7258158212d8_iv -in _build/travis-juniper.enc -out ~/.ssh/id_rsa -d
27-
chmod 600 ~/.ssh/id_rsa
23+
mkdir -p ~/.ssh
24+
openssl aes-256-cbc -K $encrypted_7258158212d8_key -iv $encrypted_7258158212d8_iv -in _build/travis-juniper.enc -out ~/.ssh/id_rsa -d
25+
chmod 600 ~/.ssh/id_rsa
2826
29-
git clone --branch gh-pages [email protected]:mhallin/juniper deploy_docs
30-
cd deploy_docs
27+
git clone --branch gh-pages [email protected]:mhallin/juniper deploy_docs
28+
cd deploy_docs
3129
32-
git config user.name 'Juniper Documentation Builder'
33-
git config user.email '[email protected]'
30+
git config user.name 'Juniper Documentation Builder'
31+
git config user.email '[email protected]'
3432
35-
rm -rf *
36-
mv ../target/doc/* .
33+
rm -rf *
34+
mv ../target/doc/* .
3735
38-
echo '<meta http-equiv="refresh" content="0; url=graphql/index.html">' > index.html
36+
echo '<meta http-equiv="refresh" content="0; url=juniper/index.html">' > index.html
3937
40-
git add -A *
41-
git commit -qm 'Update documentation for Juniper'
42-
git push -q origin gh-pages
38+
git add -A *
39+
git commit -qm 'Update documentation for Juniper'
40+
git push -q origin gh-pages
41+
fi

0 commit comments

Comments
 (0)