spreed/run-stylelint.sh
Joas Schilling 08c2d70e50
Only check (s)css files in css/
Signed-off-by: Joas Schilling <coding@schilljs.com>
2019-10-09 12:10:55 +02:00

12 lines
307 B
Bash
Executable file

#!/bin/sh
set -e
STYLELINT=$(which stylelint || true)
if [ -z "$STYLELINT" ]; then
echo "Can't find command \"stylelint\" in $PATH"
exit 1
fi
echo Checking stylesheets with $STYLELINT ...
find css/ -name "*.css" -print0 | xargs -0 $STYLELINT
find css/ -name "*.scss" -print0 | xargs -0 $STYLELINT