ci: Symlink clang-format in Dockerfile #955
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: Code Style | |
on: [push, pull_request] | |
jobs: | |
clang-format: | |
name: Clang Format | |
runs-on: ubuntu-latest | |
container: ghcr.io/yeetari/vull:master | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Run clang-format | |
shell: bash | |
run: | | |
git config --global --add safe.directory $(pwd) | |
find . \( -name '*.cc' -or -name '*.hh' \) -and -not -name 'context_table.*' -and -not -name 'vulkan.*' | xargs clang-format-16 -i | |
git diff | tee format-diff | |
if [ -s format-diff ]; then exit 1; fi | |
include-what-you-use: | |
name: Include What You Use | |
runs-on: ubuntu-latest | |
container: ghcr.io/yeetari/vull:master | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
- name: Run include-what-you-use | |
run: | | |
./tools/run_iwyu.bash | tee output | |
if [ -s output ]; then exit 1; fi |