Static-minify is a project mainly written in PHP, it's free.
Minifiy static file or group of files into a single zipped file with caching system
Add a CodeIgniter minify controller to handle your static content.
This script is using Minify (currently 2.1.3) Minify is a PHP5 app that helps you follow several of Yahoo!'s Rules for High Performance Web Sites. Read more : http://code.google.com/p/minify/
Features:
Copy and paste config/minify.php to your config directory Copy and paste controllers/min.php to your controller directory (could be in module if you are using CodeIgniter MX).
Note: you could rename min to whatever you wanted.
In your config/route.php :
$route['js/(:any)'] = "min/$1"; $route['css/(:any)'] = "min/$1";
Open config/minify.php and change the settings to your convenience.
This piece of code could be really improved and is a working draft. For instance call the propper minify script depending on the file type. For now I let Minify doing this job. Also some more config could be set if users want to minify static html, json or some other static content. One could edit controller/config for that purpose.