Skip to content

CI

CI #116

Workflow file for this run

name: CI
on:
push:
pull_request:
schedule:
- cron: '0 15 * * 0,4' # Every Monday and Friday at 00:00 JST
env:
CARGO_INCREMENTAL: 0
CARGO_NET_RETRY: 10
CARGO_TERM_COLOR: always
RUST_BACKTRACE: 1
RUSTDOCFLAGS: -D warnings
RUSTFLAGS: -D warnings
defaults:
run:
shell: bash
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true
jobs:
build:
strategy:
fail-fast: false
runs-on: ubuntu-22.04
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
- name: apt update
run: |
sudo apt-get update
- name: apt upgrade
run: |
sudo apt-get upgrade
- name: apt rust installs
run: |
sudo apt-get install -yqq cargo
sudo apt-get install -yqq rustc
sudo apt-get install -yqq librust-openssl-dev
# currently these are 1.82 (but are 1.75 on non-github-action Ubuntu 22.04)
# mostly this makes clippy fail on more things
cargo --version
rustc --version
- name: more apt installs
run: |
sudo apt-get install -yqq python3-rosmsg pkg-config rospack-tools
sudo apt-get install -yqq libactionlib-msgs-dev python3-actionlib-msgs ros-actionlib-msgs
sudo apt-get install -yqq libgeometry-msgs-dev python3-geometry-msgs ros-geometry-msgs
sudo apt-get install -yqq libsensor-msgs-dev python3-sensor-msgs ros-sensor-msgs
sudo apt-get install -yqq libstd-msgs-dev python3-std-msgs ros-std-msgs
sudo apt-get install -yqq libstd-srvs-dev python3-std-srvs ros-std-srvs
sudo apt-get install -yqq libtf2-msgs-dev python3-tf2-msgs ros-tf2-msgs
rospack find geometry_msgs
echo "ROS_PACKAGE_PATH=`rospack find geometry_msgs`:`rospack find tf2_msgs`:`rospack find sensor_msgs`:`rospack find std_msgs`:`rospack find actionlib_msgs`" >> $GITHUB_ENV
- run: |
! [[ -z "$ROS_PACKAGE_PATH" ]]
- run: echo $ROS_PACKAGE_PATH
- run: cargo build
- run: cargo test
- run: cargo fmt --check
- run: cargo clippy