aboutsummaryrefslogtreecommitdiffhomepage
path: root/dev/tools/check-eof-newline.sh
blob: 1c578c05ce2e5a158fee5126881bd7f711f8f982 (plain)
1
2
3
4
5
6
7
8
9
#!/usr/bin/env bash

if [ -z "$(tail -c 1 "$1")" ]
then
    exit 0
else
    echo "No newline at end of file $1!"
    exit 1
fi