From 8cfe3c3b03f10c26d7907f7d73dc55fd61365ae0 Mon Sep 17 00:00:00 2001 From: Filip Parag Date: Thu, 2 Dec 2021 18:56:58 +0100 Subject: [PATCH] linters --- .github/workflows/linter.yml | 37 ++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/linter.yml diff --git a/.github/workflows/linter.yml b/.github/workflows/linter.yml new file mode 100644 index 000000000..e6cc6859b --- /dev/null +++ b/.github/workflows/linter.yml @@ -0,0 +1,37 @@ +on: + push: + pull_request: + branches: + - main + +env: + CI: 1 + DEBIAN_FRONTEND: noninteractive + +jobs: + py-linter: + name: Python code checker + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + - name: Prepare system + run: | + sudo -E apt-get update + sudo -E apt-get install -y flake8 python3-flake8 + - name: Run flake8 + uses: suo/flake8-github-action@releases/v1 + with: + checkName: 'py-linter' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + cpp-linter: + name: C and C++ code checker + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v2 + - uses: shenxianpeng/cpp-linter-action@master + id: linter + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}