Skip to content

Creates a C SDK to interact with the server #4

Creates a C SDK to interact with the server

Creates a C SDK to interact with the server #4

Workflow file for this run

name: clang-tidy-review
on:
pull_request:
paths:
- '**.c'
- '**.h'
jobs:
clang-tidy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 2
- name: Install clang-tidy
run: |
sudo apt-get update
sudo apt-get install -y clang-tidy curl libcurl4
- name: Prepare compile_commands.json
run: |
cd sdks/c/ &&
cmake -B build -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
- name: Create results directory
run: |
mkdir clang-tidy-result
- name: Analyze
run: |
git diff -U0 HEAD^ | clang-tidy-diff -p1 -path build -export-fixes clang-tidy-result/fixes.yml
- name: Run clang-tidy-pr-comments action
uses: platisd/clang-tidy-pr-comments@master
with:
# The path to the clang-tidy fixes generated previously
clang_tidy_fixes: clang-tidy-result/fixes.yml
# Optionally set to true if you want the Action to request
# changes in case warnings are found
request_changes: true
# Optionally set the number of comments per review
# to avoid GitHub API timeouts for heavily loaded
# pull requests
suggestions_per_comment: 10