-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Clang-tidy off by default if present
- Loading branch information
Showing
10 changed files
with
80 additions
and
27 deletions.
There are no files selected for viewing
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
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
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
name: Clang-tidy | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
|
||
jobs: | ||
ubuntu-clang-tidy-build: | ||
name: Build on Ubuntu with clang-tidy checks | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
compiler: [clang++-13] | ||
buildmode: [Debug] | ||
|
||
steps: | ||
- name: Checkout repository code | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install dependencies | ||
run: | | ||
sudo apt update && sudo apt install libcurl4-gnutls-dev ninja-build | ||
- name: Install clang | ||
run: | | ||
wget https://apt.llvm.org/llvm.sh | ||
chmod +x llvm.sh | ||
sudo ./llvm.sh 13 | ||
- name: Install clang-tidy | ||
run: | | ||
sudo apt install clang-tidy-13 | ||
sudo ln -s /usr/bin/clang-tidy-13 /usr/bin/clang-tidy | ||
- name: Create Build Environment | ||
run: cmake -E make_directory ${{github.workspace}}/build | ||
|
||
- name: Configure CMake | ||
working-directory: ${{github.workspace}}/build | ||
shell: bash | ||
run: cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=${{matrix.buildmode}} -DCMAKE_CXX_COMPILER=${{matrix.compiler}} -DCCT_ENABLE_CLANG_TIDY=ON -GNinja | ||
|
||
- name: Build | ||
working-directory: ${{github.workspace}}/build | ||
shell: bash | ||
run: ninja | ||
|
||
- name: Local Tests | ||
working-directory: ${{github.workspace}}/build | ||
shell: bash | ||
run: ctest -j 2 -C ${{matrix.buildmode}} --output-on-failure --exclude-regex api_test | ||
|
||
- name: Public API Tests # Tries several times to avoid random timeout errors not coming from coincenter | ||
working-directory: ${{github.workspace}}/build | ||
shell: bash | ||
run: ctest -j 2 -C ${{matrix.buildmode}} --output-on-failure --tests-regex api_test --repeat until-pass:10 |
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
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
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
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
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