From a155d9199aa23be31e9856155f9d0cbf9f8ae21e Mon Sep 17 00:00:00 2001 From: drunkendog Date: Mon, 28 Aug 2023 17:29:26 +0100 Subject: [PATCH] Add --prefix check and rename code quality test to make it consistent (see #1) --- .gitea/workflows/code-quality.yaml | 13 ------------- .gitea/workflows/test-code-quality.yaml | 18 ++++++++++++++++++ 2 files changed, 18 insertions(+), 13 deletions(-) delete mode 100644 .gitea/workflows/code-quality.yaml create mode 100644 .gitea/workflows/test-code-quality.yaml diff --git a/.gitea/workflows/code-quality.yaml b/.gitea/workflows/code-quality.yaml deleted file mode 100644 index a1e21fa..0000000 --- a/.gitea/workflows/code-quality.yaml +++ /dev/null @@ -1,13 +0,0 @@ -name: Code Quality Test -on: [push, pull_request] -jobs: - Quality-Check: - runs-on: ubuntu-22.04 - steps: - - name: Check out repository code - uses: actions/checkout@v3 - - name: Check for os.system (#2) - continue-on-error: true - run: | - git ls-files | xargs grep os.system - exit $(git ls-files | xargs grep os.system | wc -l) \ No newline at end of file diff --git a/.gitea/workflows/test-code-quality.yaml b/.gitea/workflows/test-code-quality.yaml new file mode 100644 index 0000000..5d6b44f --- /dev/null +++ b/.gitea/workflows/test-code-quality.yaml @@ -0,0 +1,18 @@ +name: Code Quality Test +on: [push, pull_request] +jobs: + Quality-Check: + runs-on: ubuntu-22.04 + steps: + - name: Check out repository code + uses: actions/checkout@v3 + - name: Check for --prefix in Borg commands (\#1) + continue-on-error: true + run: | + git ls-files backup/ | xargs grep '\-\-prefix' + exit $(git ls-files backup/ | xargs grep '\-\-prefix' | wc -l) + - name: Check for os.system (\#2) + continue-on-error: true + run: | + git ls-files | xargs grep os.system + exit $(git ls-files | xargs grep os.system | wc -l) \ No newline at end of file