diff options
author | pommicket <pommicket@gmail.com> | 2025-09-08 19:48:21 -0400 |
---|---|---|
committer | pommicket <pommicket@gmail.com> | 2025-09-08 19:48:21 -0400 |
commit | aba95d2f8cd0b945a7cf774f8c628a000f601810 (patch) | |
tree | 66d18b5dfb473833ab8c01d83f11b5ec42b50a7e /pre-commit.sh | |
parent | 99ab15be006b736522017b2c16a206e6540cc57d (diff) |
Add whitespace test
Diffstat (limited to 'pre-commit.sh')
-rwxr-xr-x | pre-commit.sh | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/pre-commit.sh b/pre-commit.sh index 995cc0a..5930194 100755 --- a/pre-commit.sh +++ b/pre-commit.sh @@ -1,8 +1,7 @@ #!/bin/bash +# Check with Nu validator (https://github.com/validator/validator) if installed +which vnu >/dev/null && vnu site/*.html || exit 1 for file in site/*.html; do - echo "Checking $file..." - # Check with Nu validator (https://github.com/validator/validator) if installed - which vnu >/dev/null && vnu $file || exit 1 # /dev/null is to force file names to be printed (grep -H is a GNU extension) if grep -n '\s$' /dev/null $file; then echo "$file has trailing white space." |