lautr.com

Hannes Blog for Development and Stuff besides

include css/js minification in the release process

| 1 Kommentar

>> Update <<

I noticed that in the most scenarios you have to always delete the minified file. So i added a line to the script let it take care of that.

First, I love the YUI Compressor , its just a great, yet simple tool, unfortunately it can only handle one File (input) at the Time so I wrote a small Bash Script (thx @ sw) to handle that matter:

#!/bin/bash
rm ${!#};
i=$#
for argument in $@ ;do
if [ $argument != ${!#} ]
then
java -jar yuicompressor-2.4.2.jar $argument >> ${!#}
fi
done

Its really a great Thing to include in your Release Process, if you are like me, use an rsync script or something like that to not have all the svn stuff in your productive directory, or a lot of other possible scenarios, of course!

Autor: Hannes

Hi! I’m Johannes Lauter a 26 year old Web Application Developer based in Berlin ... more

Ein Kommentar

  1. for some reason the code highlighter doest like > … so & gt;& gt; is of course >>

Hinterlasse eine Antwort

Pflichtfelder sind mit * markiert.

*