Skip to content

Commit

Permalink
ci: Add Action to check for tabs in JSON files
Browse files Browse the repository at this point in the history
  • Loading branch information
GeckoEidechse committed Jan 12, 2024
1 parent 2d3f21a commit 296a701
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions .github/workflows/no-tabs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Check for tabs in JSON files

on: [push, pull_request]

jobs:
check-for-tabs-in-json:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check JSON files for tabs
run: |
set -e
for file in $(find . -type f -name '*.json'); do
if grep --perl-regexp --quiet '\t' "$file"; then
echo "Error: JSON file $file contains tabs."
exit 1
fi
done

0 comments on commit 296a701

Please sign in to comment.