JSC (Java Script Compressor)

2006/05/16 Kazuki Ohta

Introduction

A JavaScript Compressor, which reduces the code size of JavaScript sources. The aim is to lower the latency to load a profile of javascript library files. NOTICE, this software is still in the beta stage.

Features

Download

Install

Usage

ubuntu% ./jsc prototype-1.4.0.js > tmp2
ubuntu% ./jsc tmp2 > tmp3              
ubuntu% diff -u tmp2 tmp3 
If diff doesn't output anything, the code compressing ends successfully. You must check this. If there's a difference between tmp2 and tmp3, that's a bug of jsc. So please report to me.

Example

ubuntu% ./jsc prototype-1.4.0.js > prototype-compressed-1.4.0.js
ubuntu% ls -al prototype-1.4.0.js 
-rw-------  1 kzk kzk 47445 2006-01-21 05:09 prototype-1.4.0.js
ubuntu% ls -al prototype-compressed-1.4.0.js 
-rw-------  1 kzk kzk 34987 2006-05-16 10:50 prototype-compressed-1.4.0.js
ubuntu% ls -al prototype-1.4.0.js.gz           
-rw-------  1 kzk kzk 10543 2006-01-21 05:09 prototype-1.4.0.js.gz
ubuntu% ls -al prototype-compressed-1.4.0.js.gz 
-rw-------  1 kzk kzk 8544 2006-05-16 11:16 prototype-compressed-1.4.0.js.gz

Future Plans

History

[ return ]