LDAPAccountManager/lam-packaging/debian/minify

19 lines
404 B
Plaintext
Raw Normal View History

2014-03-08 13:37:43 +00:00
#!/bin/bash
set -e
2016-08-27 20:28:37 +00:00
files=`ls templates/lib/*.js style/*.css`
2014-03-08 13:37:43 +00:00
for file in $files; do
# skip dropmenu file, incompatible with YUI compressor
if [[ $file =~ .*dropmenu.* ]]; then
continue
fi
yui-compressor --nomunge --preserve-semi --disable-optimizations --charset UTF-8 -o ${file}-MIN $file
rm $file
mv ${file}-MIN $file
# add final new line to supress Debian warnings
echo "" >> $file
done