forked from moveit/moveit_tutorials
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
65 lines (59 loc) · 2.33 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
# Test build the MoveIt tutorials. Author: Dave Coleman
sudo: required
dist: xenial
language: ruby
rvm:
- 2.4
python:
- "2.7"
cache: ccache
compiler: gcc
before_install: # Use this to prepare the system to install prerequisites or dependencies
# Define some config vars
- export ROS_DISTRO=melodic
- export DOCKER_IMAGE=moveit/moveit:master-source
- export NOKOGIRI_USE_SYSTEM_LIBRARIES=true
- export REPOSITORY_NAME=${PWD##*/}
- echo "Testing branch $TRAVIS_BRANCH of $REPOSITORY_NAME"
- sudo -E sh -c 'echo "deb http://packages.ros.org/ros/ubuntu `lsb_release -cs` main" > /etc/apt/sources.list.d/ros-latest.list'
- wget http://packages.ros.org/ros.key -O - | sudo apt-key add -
- sudo apt-get update -qq
- sudo apt-get install -qq -y python-rosdep python-wstool python-catkin-tools
# Setup rosdep
- sudo rosdep init
- rosdep update
# Install htmlpoofer
- gem update --system
- gem --version
- gem install html-proofer
# Install ROS's version of sphinx
- sudo apt-get -qq install ros-kinetic-rosdoc-lite
- source /opt/ros/kinetic/setup.bash
before_script:
- git clone -q --depth=1 https://github.com/ros-planning/moveit_ci.git .moveit_ci
script:
# Build tutorial examples
- .moveit_ci/travis.sh
# Test build with non-ROS wrapped Sphinx command to allow warnings and errors to be caught
- sphinx-build -W -b html . native_build
# Test build with ROS-version of Sphinx command so that it is generated same as ros.org
- rosdoc_lite -o build .
# Run HTML tests on generated build output to check for 404 errors, etc
- test "$TRAVIS_PULL_REQUEST" == false || URL_SWAP="--url-swap https\://github.com/ros-planning/moveit_tutorials/blob/master/:file\://$PWD/build/html/"
- htmlproofer ./build --only-4xx --check-html --file-ignore ./build/html/genindex.html,./build/html/search.html --alt-ignore '/.*/' --url-ignore '#' $URL_SWAP
# after_success and deploy are skipped if build is broken
after_success:
# Tell GitHub Pages not to bypass Jekyll processing
- touch build/html/.nojekyll
deploy:
# Deploy to gh-pages branch
provider: pages
# Don't delete built files
skip-cleanup: true
# Add to Environment Variables section of Travis CI repository settings page
github-token: $GITHUB_TOKEN
# Only copy build output directory to gh-pages
local_dir: build/html
on:
# Source branch
branch: master