erplibre/script/maintenance/prettier.sh

10 lines
278 B
Bash
Raw Normal View History

#!/usr/bin/env bash
# This will format all js,css,html
# argument 1: directory or file to format
./node_modules/.bin/prettier --tab-width 4 --print-width 120 --no-bracket-spacing --write "$@"
2021-06-27 00:22:22 -04:00
retVal=$?
if [[ $retVal -ne 0 ]]; then
echo "Error prettier format"
exit 1
fi