From 9bd0644982cbafb391a0030f1484426f78568853 Mon Sep 17 00:00:00 2001 From: Jared Van Bortel Date: Mon, 21 Oct 2024 15:50:06 -0400 Subject: [PATCH] github: add clazy to linting workflow Signed-off-by: Jared Van Bortel --- .github/workflows/codespell.yml | 19 ----------------- .github/workflows/lint.yml | 36 +++++++++++++++++++++++++++++++++ 2 files changed, 36 insertions(+), 19 deletions(-) delete mode 100644 .github/workflows/codespell.yml create mode 100644 .github/workflows/lint.yml diff --git a/.github/workflows/codespell.yml b/.github/workflows/codespell.yml deleted file mode 100644 index 3bda7023..00000000 --- a/.github/workflows/codespell.yml +++ /dev/null @@ -1,19 +0,0 @@ ---- -name: Codespell - -on: - push: - branches: [main] - pull_request: - branches: [main] - -jobs: - codespell: - name: Check for spelling errors - runs-on: ubuntu-latest - - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Codespell - uses: codespell-project/actions-codespell@v2 diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml new file mode 100644 index 00000000..e218ef3b --- /dev/null +++ b/.github/workflows/lint.yml @@ -0,0 +1,36 @@ +--- +name: Lint + +on: [push, pull_request] + +jobs: + codespell: + name: Codespell + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4.2.1 + - name: Codespell + uses: codespell-project/actions-codespell@v2.1 + + clazy: + name: Clazy + runs-on: ubuntu-latest + + steps: + - name: Checkout + uses: actions/checkout@v4.2.1 + - name: Configure + run: | + cmake -S gpt4all-chat -B gpt4all-chat/build \ + -DCMAKE_C_COMPILER=clang \ + -DCMAKE_CXX_COMPILER=clang++ \ + -DLLMODEL_CUDA=OFF \ + -DLLMODEL_KOMPUTE=OFF + - name: Clazy + uses: MinyazevR/clazy-standalone-action@v0.2.0 + with: + checks: "level0,no-container-anti-pattern,no-qstring-arg,no-qstring-ref,no-strict-iterators,no-unused-non-trivial-variable" + install-stable: true + database: gpt4all-chat/build