Setup clang format for C code #2
Workflow file for this run
This file contains hidden or 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: C Code Linting | |
on: | |
push: | |
paths: | |
- '**.c' | |
- '**.h' | |
- '.clang-format' | |
- '.github/workflows/clang-format.yml' | |
pull_request: | |
paths: | |
- '**.c' | |
- '**.h' | |
- '.clang-format' | |
- '.github/workflows/clang-format.yml' | |
jobs: | |
format-check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install clang-format | |
run: sudo apt-get install -y clang-format | |
- name: Setup Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: '3.4' | |
bundler-cache: true | |
- name: Check C code linting | |
run: bundle exec rake format:c_check |