forked from ros-controls/control_toolbox
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update CI config and add pre-commit-config.
- Loading branch information
Showing
12 changed files
with
516 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
name: Build Source | ||
on: | ||
push: | ||
branches: | ||
- ros2-master | ||
schedule: | ||
# Run every day to detect flakiness and broken dependencies | ||
- cron: '28 3 * * *' | ||
|
||
jobs: | ||
source: | ||
name: source build | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
fail-fast: false | ||
steps: | ||
- uses: ros-tooling/[email protected] | ||
- uses: ros-tooling/[email protected] | ||
with: | ||
target-ros2-distro: rolling | ||
# build all packages listed in the meta package | ||
package-name: | ||
control_toolbox | ||
vcs-repo-file-url: | | ||
https://raw.githubusercontent.com/ros-controls/control_toolbox/ros2-master/control_toolbox.rosinstall | ||
colcon-defaults: | | ||
{ | ||
"build": { | ||
"mixin": ["coverage-gcc"] | ||
} | ||
} | ||
colcon-mixin-repository: https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml | ||
- uses: codecov/[email protected] | ||
with: | ||
file: ros_ws/lcov/total_coverage.info | ||
flags: unittests | ||
name: codecov-umbrella | ||
- uses: actions/upload-artifact@v1 | ||
with: | ||
name: colcon-logs-${{ matrix.os }} | ||
path: ros_ws/log | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
# This config uses industrial_ci (https://github.com/ros-industrial/industrial_ci.git). | ||
# For troubleshooting, see readme (https://github.com/ros-industrial/industrial_ci/blob/master/README.rst) | ||
|
||
name: Build | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- ros2-master | ||
schedule: | ||
# Run every day to detect flakiness and broken dependencies | ||
- cron: '28 6 * * *' | ||
|
||
jobs: | ||
binary: | ||
name: binary build | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
env: | ||
- {ROS_DISTRO: foxy, ROS_REPO: main} | ||
- {ROS_DISTRO: foxy, ROS_REPO: testing} | ||
env: | ||
CCACHE_DIR: ${{ github.workspace }}/.ccache | ||
BASEDIR: ${{ github.workspace }}/.work | ||
CACHE_PREFIX: ${{ matrix.env.ROS_DISTRO }}-${{ matrix.env.ROS_REPO }} | ||
DOWNSTREAM_WORKSPACE: https://raw.githubusercontent.com/ros-controls/ros2_control/master/ros2_control/ros2_control.repos | ||
steps: | ||
- uses: actions/checkout@v1 | ||
# The target directory cache doesn't include the source directory because | ||
# that comes from the checkout. See "prepare target_ws for cache" task below | ||
- name: cache target_ws | ||
if: ${{ ! matrix.env.CCOV }} | ||
uses: pat-s/[email protected] | ||
with: | ||
path: ${{ env.BASEDIR }}/target_ws | ||
key: target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }}-${{ github.run_id }} | ||
restore-keys: | | ||
target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }} | ||
- name: cache ccache | ||
uses: pat-s/[email protected] | ||
with: | ||
path: ${{ env.CCACHE_DIR }} | ||
key: ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }}-${{ github.run_id }} | ||
restore-keys: | | ||
ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }} | ||
ccache-${{ env.CACHE_PREFIX }} | ||
- uses: 'ros-industrial/industrial_ci@master' | ||
env: ${{matrix.env}} | ||
- name: prepare target_ws for cache | ||
if: ${{ always() && ! matrix.env.CCOV }} | ||
run: | | ||
du -sh ${{ env.BASEDIR }}/target_ws | ||
sudo find ${{ env.BASEDIR }}/target_ws -wholename '*/test_results/*' -delete | ||
sudo rm -rf ${{ env.BASEDIR }}/target_ws/src | ||
du -sh ${{ env.BASEDIR }}/target_ws |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# This config uses industrial_ci (https://github.com/ros-industrial/industrial_ci.git). | ||
# For troubleshooting, see readme (https://github.com/ros-industrial/industrial_ci/blob/master/README.rst) | ||
|
||
name: Build galactic | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- ros2-master | ||
schedule: | ||
# Run every day to detect flakiness and broken dependencies | ||
- cron: '28 6 * * *' | ||
|
||
jobs: | ||
binary: | ||
name: binary build | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
env: | ||
- {ROS_DISTRO: galactic, ROS_REPO: main} | ||
- {ROS_DISTRO: galactic, ROS_REPO: testing} | ||
env: | ||
CCACHE_DIR: ${{ github.workspace }}/.ccache | ||
BASEDIR: ${{ github.workspace }}/.work | ||
CACHE_PREFIX: ${{ matrix.env.ROS_DISTRO }}-${{ matrix.env.ROS_REPO }} | ||
DOWNSTREAM_WORKSPACE: https://raw.githubusercontent.com/ros-controls/ros2_control/master/ros2_control/ros2_control.repos | ||
steps: | ||
- uses: actions/checkout@v1 | ||
# The target directory cache doesn't include the source directory because | ||
# that comes from the checkout. See "prepare target_ws for cache" task below | ||
- name: cache target_ws | ||
if: ${{ ! matrix.env.CCOV }} | ||
uses: pat-s/[email protected] | ||
with: | ||
path: ${{ env.BASEDIR }}/target_ws | ||
key: target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }}-${{ github.run_id }} | ||
restore-keys: | | ||
target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }} | ||
- name: cache ccache | ||
uses: pat-s/[email protected] | ||
with: | ||
path: ${{ env.CCACHE_DIR }} | ||
key: ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }}-${{ github.run_id }} | ||
restore-keys: | | ||
ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }} | ||
ccache-${{ env.CACHE_PREFIX }} | ||
- uses: 'ros-industrial/industrial_ci@master' | ||
env: ${{matrix.env}} | ||
- name: prepare target_ws for cache | ||
if: ${{ always() && ! matrix.env.CCOV }} | ||
run: | | ||
du -sh ${{ env.BASEDIR }}/target_ws | ||
sudo find ${{ env.BASEDIR }}/target_ws -wholename '*/test_results/*' -delete | ||
sudo rm -rf ${{ env.BASEDIR }}/target_ws/src | ||
du -sh ${{ env.BASEDIR }}/target_ws | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
# This config uses industrial_ci (https://github.com/ros-industrial/industrial_ci.git). | ||
# For troubleshooting, see readme (https://github.com/ros-industrial/industrial_ci/blob/master/README.rst) | ||
|
||
name: Build rolling | ||
on: | ||
pull_request: | ||
push: | ||
branches: | ||
- ros2-master | ||
schedule: | ||
# Run every day to detect flakiness and broken dependencies | ||
- cron: '28 6 * * *' | ||
|
||
jobs: | ||
binary: | ||
name: binary build | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
env: | ||
- {ROS_DISTRO: rolling, ROS_REPO: main} | ||
- {ROS_DISTRO: rolling, ROS_REPO: testing} | ||
env: | ||
CCACHE_DIR: ${{ github.workspace }}/.ccache | ||
BASEDIR: ${{ github.workspace }}/.work | ||
CACHE_PREFIX: ${{ matrix.env.ROS_DISTRO }}-${{ matrix.env.ROS_REPO }} | ||
DOWNSTREAM_WORKSPACE: https://raw.githubusercontent.com/ros-controls/ros2_control/master/ros2_control/ros2_control.repos | ||
steps: | ||
- uses: actions/checkout@v1 | ||
# The target directory cache doesn't include the source directory because | ||
# that comes from the checkout. See "prepare target_ws for cache" task below | ||
- name: cache target_ws | ||
if: ${{ ! matrix.env.CCOV }} | ||
uses: pat-s/[email protected] | ||
with: | ||
path: ${{ env.BASEDIR }}/target_ws | ||
key: target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }}-${{ github.run_id }} | ||
restore-keys: | | ||
target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }} | ||
- name: cache ccache | ||
uses: pat-s/[email protected] | ||
with: | ||
path: ${{ env.CCACHE_DIR }} | ||
key: ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }}-${{ github.run_id }} | ||
restore-keys: | | ||
ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }} | ||
ccache-${{ env.CACHE_PREFIX }} | ||
- uses: 'ros-industrial/industrial_ci@master' | ||
env: ${{matrix.env}} | ||
- name: prepare target_ws for cache | ||
if: ${{ always() && ! matrix.env.CCOV }} | ||
run: | | ||
du -sh ${{ env.BASEDIR }}/target_ws | ||
sudo find ${{ env.BASEDIR }}/target_ws -wholename '*/test_results/*' -delete | ||
sudo rm -rf ${{ env.BASEDIR }}/target_ws/src | ||
du -sh ${{ env.BASEDIR }}/target_ws | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: Build Source galactic | ||
on: | ||
push: | ||
branches: | ||
- ros2-master | ||
schedule: | ||
# Run every day to detect flakiness and broken dependencies | ||
- cron: '28 3 * * *' | ||
|
||
jobs: | ||
source: | ||
name: source build | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
fail-fast: false | ||
steps: | ||
- uses: ros-tooling/[email protected] | ||
- uses: ros-tooling/[email protected] | ||
with: | ||
vcs-repo-file-url: | | ||
https://raw.githubusercontent.com/ros-controls/control_toolbox/ros2-master/control_toolbox.rosinstall | ||
https://raw.githubusercontent.com/ros2/ros2/master/ros2.repos | ||
package-name: control_toolbox | ||
colcon-mixin-name: coverage-gcc | ||
colcon-mixin-repository: https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml | ||
target-ros2-distro: galactic | ||
- uses: actions/upload-artifact@v1 | ||
with: | ||
name: colcon-logs-${{ matrix.os }} | ||
path: ros_ws/log | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Build Source rolling | ||
on: | ||
push: | ||
branches: | ||
- ros2-master | ||
schedule: | ||
# Run every day to detect flakiness and broken dependencies | ||
- cron: '28 3 * * *' | ||
|
||
jobs: | ||
source: | ||
name: source build | ||
runs-on: ubuntu-20.04 | ||
strategy: | ||
fail-fast: false | ||
steps: | ||
- uses: ros-tooling/[email protected] | ||
- uses: ros-tooling/[email protected] | ||
with: | ||
vcs-repo-file-url: | | ||
https://raw.githubusercontent.com/ros-controls/control_toolbox/ros2-master/control_toolbox.rosinstall | ||
https://raw.githubusercontent.com/ros2/ros2/master/ros2.repos | ||
package-name: control_toolbox | ||
colcon-mixin-name: coverage-gcc | ||
colcon-mixin-repository: https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml | ||
target-ros2-distro: rolling | ||
- uses: actions/upload-artifact@v1 | ||
with: | ||
name: colcon-logs-${{ matrix.os }} | ||
path: ros_ws/log |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
# This is a format job. Pre-commit has a first-party GitHub action, so we use | ||
# that: https://github.com/pre-commit/action | ||
|
||
name: Format | ||
|
||
on: | ||
workflow_dispatch: | ||
pull_request: | ||
push: | ||
branches: | ||
- ros2-master | ||
|
||
jobs: | ||
pre-commit: | ||
name: Format | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- name: Install clang-format-10 | ||
run: sudo apt-get install clang-format-10 cppcheck | ||
- uses: pre-commit/[email protected] | ||
with: | ||
extra_args: --all-files --hook-stage manual | ||
token: ${{ secrets.GITHUB_TOKEN }} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.