From 81c8ded93c9a62c7798c4b6d819941b8e0a7f784 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Wed, 27 Jan 2021 22:53:52 +0100 Subject: [PATCH] :construction_worker: add CI steps for Clang-Tidy --- .github/workflows/macos.yml | 2 +- .github/workflows/ubuntu.yml | 23 ++++++----------------- .github/workflows/windows.yml | 8 ++++---- 3 files changed, 11 insertions(+), 22 deletions(-) diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index 5b178ad05..aad3a787d 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -8,7 +8,7 @@ jobs: runs-on: macos-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: cmake run: cmake -S . -B build -D CMAKE_BUILD_TYPE=Debug -DJSON_BuildTests=On - name: build diff --git a/.github/workflows/ubuntu.yml b/.github/workflows/ubuntu.yml index 10c6fbf26..e11d5cd64 100644 --- a/.github/workflows/ubuntu.yml +++ b/.github/workflows/ubuntu.yml @@ -6,7 +6,7 @@ jobs: ci_test_clang_cxx20: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: install_clang run: | sudo apt update @@ -20,7 +20,7 @@ jobs: ci_clang_analyze: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: install_ninja run: | sudo apt update @@ -41,7 +41,7 @@ jobs: ci_test_clang: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: install_ninja run: | sudo apt update @@ -92,7 +92,7 @@ jobs: ci_cpplint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: cmake run: cmake -S . -B build -DJSON_CI=On - name: build @@ -100,20 +100,9 @@ jobs: ci_clang_tidy: runs-on: ubuntu-latest + container: nlohmann/json-ci:latest steps: - - uses: actions/checkout@v1 - - name: install_ninja - run: | - sudo apt update - sudo apt install ninja-build - shell: bash - - name: install_clang - run: | - wget https://apt.llvm.org/llvm.sh - chmod +x llvm.sh - sudo ./llvm.sh 11 - sudo apt-get install clang-tools-11 - shell: bash + - uses: actions/checkout@v2 - name: cmake run: cmake -S . -B build -DJSON_CI=On - name: build diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 1778c9418..ae243762f 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -7,7 +7,7 @@ jobs: runs-on: windows-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: cmake run: cmake -S . -B build -G "Visual Studio 16 2019" -D CMAKE_BUILD_TYPE=Debug -DJSON_BuildTests=On - name: build @@ -19,7 +19,7 @@ jobs: runs-on: windows-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: install Clang run: curl -fsSL -o LLVM10.exe https://github.com/llvm/llvm-project/releases/download/llvmorg-10.0.0/LLVM-10.0.0-win64.exe ; 7z x LLVM10.exe -y -o"C:/Program Files/LLVM" - name: cmake @@ -33,7 +33,7 @@ jobs: runs-on: windows-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: cmake run: cmake -S . -B build -G "Visual Studio 16 2019" -A x64 -T ClangCL -DJSON_BuildTests=On - name: build @@ -45,7 +45,7 @@ jobs: runs-on: windows-latest steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v2 - name: cmake run: cmake -S . -B build -G "Visual Studio 16 2019" -A Win32 -T ClangCL -DJSON_BuildTests=On - name: build