neur0toxine.pages.neur0tx.site/.zs/posthook

18 lines
273 B
Plaintext
Raw Normal View History

2023-11-12 22:41:53 +03:00
#!/bin/sh
set -e
minify_assets() {
p="$1"
t="$2"
find "$p" -type f -name "*.$t" | while read -r file; do
name="${file#"$p"}"
name="${name#"/"}"
minify -o "${p}/${name}" "$file"
done
}
minify_assets "$ZS_OUTDIR" "css"
minify_assets "$ZS_OUTDIR" "js"