blob: 995cc0a82f7df05f780153c47e9e1fccd908dded (
plain)
1
2
3
4
5
6
7
8
9
10
11
|
#!/bin/bash
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."
exit 1
fi
done
|