juicer icon indicating copy to clipboard operation
juicer copied to clipboard

Reflect minification result using the exit code

Open garside opened this issue 12 years ago • 0 comments

When the underlying minifier runs, it "silently fails" as Juicer returns with a 0 exit code regardless of the status of the underlying minifier.

If the tool could bubble up any underlying compiler exceptions through a non-zero exit code, these sort of compiler failures can be programmatically detected and dealt with.

Example:

~/ $ juicer merge lib/jquery/jquery/jquery.js --skip-verification [ERROR] 4051:32:missing name after . operator

... snip ...

[ERROR] 1:0:Compilation produced 30 syntax errors. org.mozilla.javascript.EvaluatorException: Compilation produced 30 syntax errors. ... snip ... at com.yahoo.platform.yui.compressor.Bootstrap.main(Bootstrap.java:21) Produced lib/jquery/jquery/jquery.min.js from lib/jquery/jquery/jquery.js

~/ $ echo $? 0

garside avatar Jun 24 '13 14:06 garside