summaryrefslogtreecommitdiff
path: root/tools/check-whitespace.sh
blob: 5348331261728883cdbb607eac0cbac725bec52b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/bin/sh

fail=0

if grep -n ' $' "$@"
then
  echo "^^^ The above files contain unwanted trailing spaces"
  fail=1
fi

if grep -n '	' "$@"
then
  echo "^^^ The above files contain tabs"
  fail=1
fi

exit $fail