forked from mirror/earl-grey
29 lines
754 B
Bash
Executable File
29 lines
754 B
Bash
Executable File
#!/usr/bin/env bash
|
|
# This script is released into the public domain. Anyone is free to copy,
|
|
# modify, publish, or use this script for any purpose, commercial or
|
|
# non-commercial, and by any means. This notice applies only to this script
|
|
# and NOT any of the associated files. Please support open-source software!
|
|
|
|
case $1 in
|
|
"minify_prep")
|
|
for f in theme-committed-violet*.css ;do
|
|
mv $f ${f/".css"/".ccss"}
|
|
done
|
|
;;
|
|
"gen_minify")
|
|
if [ ! -f "theme-committed-violet.ccss" ];then
|
|
minify_prep
|
|
fi
|
|
if [ ! -x "node_modules/.bin/cleancss" ];then
|
|
minify_deps
|
|
fi
|
|
for c in theme-committed-violet*.ccss ;do
|
|
node_modules/.bin/cleancss -o ${c/".ccss"/".css"} $c
|
|
done
|
|
;;
|
|
*)
|
|
echo "ERROR: Use gen.sh to call this"
|
|
exit 2
|
|
;;
|
|
esac
|