Make shellcheck happier
This commit is contained in:
13
prettier.sh
13
prettier.sh
@@ -9,17 +9,20 @@ source "$DIR/_reformat-common.bash"
|
||||
|
||||
file="$1"
|
||||
|
||||
wrflog running against file $file
|
||||
wrflog running against file "$file"
|
||||
|
||||
if [[ x"$WOULD_REFORMAT" = x"would_reformat" ]] ; then
|
||||
out=$(npx prettier --check $file 2>&1 >/dev/null)
|
||||
if [[ "$WOULD_REFORMAT" = "would_reformat" ]] ; then
|
||||
out=$(npx prettier --check "$file" 2>&1 >/dev/null)
|
||||
retval="$?"
|
||||
echo "$out"
|
||||
exit "$retval"
|
||||
fi
|
||||
|
||||
if [[ x"$WOULD_REFORMAT" = x"do_reformat" ]] ; then #
|
||||
out=$(npx prettier --write $file 2>&1 >/dev/null)
|
||||
if [[ "$WOULD_REFORMAT" = "do_reformat" ]] ; then
|
||||
out=$(npx prettier --write "$file" 2>&1 >/dev/null)
|
||||
retval="$?"
|
||||
|
||||
echo "$out"
|
||||
exit "$retval"
|
||||
fi
|
||||
|
||||
|
||||
Reference in New Issue
Block a user