I typed D:\yuicompressor-2.42\build in Path and save it (Windows XP). But when I tried executing it the command line displayed: unable to access jarfile. The same message that appear when I type an incorrect directory.
I tried executing the file in this way:
D:\wamp\www\projects\alexchen\alexchen 0.1\scripts>java -jar yuicompressor-2.4.2.jar custom.js -o custom.min.js
I tried calling the file directly and it works:
D:\wamp\www\projects\alexchen\alexchen 0.1\scripts>java -jar D:\yuicompressor-2.4.2\build\yuicompressor-2.4.2.jar custom.js -o custom.min.js
Probably you’ve misread the docs:
This means that you should specify full path to your jar file, not to put it in the Path env variable.