Make Travis upload to doc.servo.org again.

This commit is contained in:
Simon Sapin 2014-09-15 18:20:31 +01:00
parent 11ba79894a
commit 547b5ea6fb
2 changed files with 17 additions and 26 deletions

View file

@ -1,9 +1,5 @@
language: c
os:
- linux
- osx
install: ./etc/ci/travis.install.sh
before_script: ./etc/ci/travis.before_script.sh
@ -25,10 +21,12 @@ env:
- LD_LIBRARY_PATH: /usr/local/lib
- secure: "C/9/o+5KdTY1LZ4qZGE1+gY6mEGamG/VDHP69Om9dklfchJD6C+j8K8dvmE26FeRnLhSL7eGf1b3m6lfgkTZeVFjjiZE0Exvf1yI9Y3QPWR7ViaFxWk1z1I4HaSu4fpBo++e8FW+0EGjIkIrRtAn+bav3eDpAhgSih10KmAx4a8="
matrix:
- TASKS=build,test-content,test-ref,build-cef
- TASKS=build,test-content,test-ref,push-doc,build-cef
matrix:
include:
- os: osx
env: TASKS=build,test-content,test-ref,build-cef
- os: osx
env: TASKS=build,test-wpt1
- os: osx

View file

@ -2,27 +2,6 @@
set -e
build_docs() {
./mach doc
cp etc/doc.servo.org/* target/doc/
cp -R rust/doc/* target/doc/
if [ "${TRAVIS_BRANCH}" = "master" ] && [ "${TRAVIS_PULL_REQUEST}" = "false" ]; then
echo '<meta http-equiv=refresh content=0;url=servo/index.html>' > target/doc/index.html
sudo pip install ghp-import
ghp-import -n target/doc
git push -qf https://${TOKEN}@github.com/servo/doc.servo.org.git gh-pages
fi
}
build_servo() {
./mach build -j 2
}
build_cef() {
./mach build-cef -j 2
}
IFS="," read -ra tasks <<< "${TASKS}"
for t in "${tasks[@]}"; do
# OS specific setup
@ -54,6 +33,20 @@ for t in "${tasks[@]}"; do
test-wpt1)
./mach test-wpt --processes=2 --total-chunks=2 --this-chunk=2
;;
push-doc)
if [ "${TRAVIS_BRANCH}" = "master" ] && [ "${TRAVIS_PULL_REQUEST}" = "false" ]
then
mkdir -p target/doc
cp etc/doc.servo.org/* target/doc/
cp -R rust/doc/* target/doc/
./mach doc # After copying rust/doc, so that the crate index is correct.
sudo pip install ghp-import
ghp-import -n target/doc
git push -qf https://${TOKEN}@github.com/servo/doc.servo.org.git gh-pages
else
echo Skipping rustdoc
fi
;;
*)
echo "Task $t not recognized."
;;