Change clang test #63
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
name: CI | |
on: [push, pull_request] | |
jobs: | |
industrial_ci: | |
strategy: | |
matrix: | |
env: | |
- {OS_NAME: ubuntu, OS_CODE_NAME: focal, ROS_DISTRO: noetic, DOCKER_IMAGE: "samxl/scancontrol:sdk_v1.0.0"} | |
env: | |
CCACHE_DIR: /github/home/.ccache | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/cache@v2 | |
with: | |
path: ${{ env.CCACHE_DIR }} | |
key: ccache-${{ matrix.env.ROS_DISTRO }}-${{ matrix.env.ROS_REPO }} | |
- uses: 'ros-industrial/industrial_ci@master' | |
env: ${{ matrix.env }} | |
clang_format_check: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@v2 | |
- name: Run Clang Format Check | |
run: | | |
find . -name "*.cpp" -o -name "*.hpp" | xargs clang-format-10 --output-replacements-xml | grep -c "<replacement " | |
if [ $? -eq 0 ]; then | |
echo "Clang Format check failed. Please run clang-format locally and commit the changes." | |
exit 1 | |
fi |