From 2d2053e0ae729863b8c4e46a1d1393ba0dab8da2 Mon Sep 17 00:00:00 2001 From: Sarah German Date: Mon, 5 Dec 2022 11:28:49 -0600 Subject: Fix minify parameters --- scripts/minify-assets.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'scripts') diff --git a/scripts/minify-assets.sh b/scripts/minify-assets.sh index cde1c20d..3cca8789 100755 --- a/scripts/minify-assets.sh +++ b/scripts/minify-assets.sh @@ -2,7 +2,7 @@ TARGET="$1" VER="$2" -MINIFY_FLAGS="--html-keep-document-tags --html-keep-whitespace --recursive" +MINIFY_FLAGS=("--html-keep-document-tags" "--html-keep-whitespace" "--recursive") if [ -z "$TARGET" ] || [ -z "$VER" ]; then echo "Usage: $0 " @@ -33,9 +33,9 @@ fi # Minify assets printf "Optimizing assets..." -printf "HTML..."; $MINIFY_BIN "$MINIFY_FLAGS" --type=html --match="\.html$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true -printf "CSS..." ; $MINIFY_BIN "$MINIFY_FLAGS" --type=css --match="\.css$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true -printf "JSON..."; $MINIFY_BIN "$MINIFY_FLAGS" --type=json --match="\.json$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true -printf "SVG..." ; $MINIFY_BIN "$MINIFY_FLAGS" --type=svg --match="\.svg$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true +printf "HTML..."; $MINIFY_BIN "${MINIFY_FLAGS[@]}" --type=html --match="\.html$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true +printf "CSS..." ; $MINIFY_BIN "${MINIFY_FLAGS[@]}" --type=css --match="\.css$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true +printf "JSON..."; $MINIFY_BIN "${MINIFY_FLAGS[@]}" --type=json --match="\.json$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true +printf "SVG..." ; $MINIFY_BIN "${MINIFY_FLAGS[@]}" --type=svg --match="\.svg$" -o "${TARGET}/${VER}/" "${TARGET}/${VER}" || true echo "Done" -- cgit v1.2.3