Files
cc65/.github/checks/lineendings.sh
Kugel Fuhr fa81f14cbf Add an explicit "exit 0" to the shell scripts. This worked more or less by
coincidence before since shell scripts return the exit code of the last
command run if there is no explicit exit statement.
2025-06-25 20:34:41 +02:00

20 lines
489 B
Bash
Executable File

#! /bin/bash
OLDCWD=`pwd`
SCRIPT_PATH=`dirname $0`
CHECK_PATH=.
cd $SCRIPT_PATH/../../
FILES=`find $CHECK_PATH -type f \( -name \*.inc -o -name Makefile -o -name \*.cfg -o -name \*.\[chs\] -o -name \*.mac -o -name \*.asm -o -name \*.sgml \) -print | grep -v "libwrk/" | grep -v "testwrk/" | xargs grep -IUl $'\r'`
cd $OLDCWD
if [ x"$FILES"x != xx ]; then
echo "error: found CR in the following files:" >&2
for n in $FILES; do
echo $n >&2
done
exit -1
fi
exit 0