Use clang-format executable #1041
Workflow file for this run
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: Clang-Format | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
schedule: | |
- cron: '0 5 * * *' | |
jobs: | |
clang_format: | |
name: Clang-Format | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Install clang format | |
run: | | |
sudo apt update -qq | |
sudo apt install -y -qq git clang-format coreutils | |
- name: Run clang format | |
run: | | |
./.run-clang-format | |
output=$(git diff) | |
git diff --color-words | cat | |
if [ -n "$output" ]; then exit 1; else exit 0; fi |