From 42fa4b642bdd5bc3b2753f1ea0f655904f2579f7 Mon Sep 17 00:00:00 2001 From: Stefan Weil Date: Sat, 16 Jul 2022 07:25:24 +0200 Subject: [PATCH] Add check for pull requests (GitHub action) Signed-off-by: Stefan Weil --- .github/workflows/pr_check.yml | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 .github/workflows/pr_check.yml diff --git a/.github/workflows/pr_check.yml b/.github/workflows/pr_check.yml new file mode 100644 index 000000000..2c30b16d3 --- /dev/null +++ b/.github/workflows/pr_check.yml @@ -0,0 +1,21 @@ +# Check pull requests. + +name: Check pull request + +# https://docs.github.com/en/actions/using-workflows/events-that-trigger-workflows +on: + # Trigger workflow on pull request. + pull_request: + # branches: [ ci ] + +jobs: + check_pull_request: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 2 + - name: Check for whitespace issues. + run: git diff --check HEAD^ + # TODO: Add more checks here (codespell, ...).