add warnings as toplevel shorthand
This commit is contained in:
parent
e6368b61a6
commit
0792c77564
|
|
@ -97,9 +97,8 @@ if (program.sourceMap && "base" in program.sourceMap) {
|
|||
};
|
||||
}();
|
||||
}
|
||||
if (program.verbose && options.compress) {
|
||||
if (typeof options.compress != "object") options.compress = {};
|
||||
options.compress.warnings = "verbose";
|
||||
if (program.verbose) {
|
||||
options.warnings = "verbose";
|
||||
}
|
||||
if (program.self) {
|
||||
if (program.args.length) {
|
||||
|
|
|
|||
|
|
@ -42,11 +42,13 @@ function minify(files, options) {
|
|||
parse: {},
|
||||
sourceMap: false,
|
||||
toplevel: false,
|
||||
warnings: true,
|
||||
wrap: false,
|
||||
}, true);
|
||||
set_shorthand("ie8", options, [ "compress", "mangle", "output" ]);
|
||||
set_shorthand("keep_fnames", options, [ "compress", "mangle" ]);
|
||||
set_shorthand("toplevel", options, [ "compress", "mangle" ]);
|
||||
set_shorthand("warnings", options, [ "compress" ]);
|
||||
if (options.mangle) {
|
||||
options.mangle = defaults(options.mangle, {
|
||||
cache: null,
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user