Add a check for trailing whitespace and TABs

Just use Git itself to check for it in the new files.
This commit is contained in:
Vadim Zeitlin
2020-09-28 02:43:26 +02:00
parent daa6eca2e7
commit 5358dd7007

View File

@@ -41,3 +41,22 @@ jobs:
- name: Run codespell - name: Run codespell
run: | run: |
CODESPELL=$HOME/.local/bin/codespell ./misc/scripts/spellcheck CODESPELL=$HOME/.local/bin/codespell ./misc/scripts/spellcheck
check-whitespace:
runs-on: ubuntu-20.04
name: Check Whitespace
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Check for trailing whitespace and TABs
run: |
git fetch --depth=1 origin master
git -c core.whitespace=blank-at-eol,blank-at-eof,space-before-tab,cr-at-eol,tab-in-indent \
diff --check origin/master '*' \
'!**/*akefile*' \
'!**/*.sln' \
'!**/*.vcproj' \
'!**/*.xpm'