add 6to5-minify
This commit is contained in:
7
bin/6to5-minify
Executable file
7
bin/6to5-minify
Executable file
@@ -0,0 +1,7 @@
|
||||
#!/usr/bin/env node
|
||||
|
||||
var opts = require("./6to5").opts;
|
||||
opts.optional = (opts.optional || []).concat("minification");
|
||||
opts.format = {
|
||||
compact: true
|
||||
};
|
||||
@@ -114,12 +114,17 @@ exports.opts = {
|
||||
loose: commander.loose
|
||||
};
|
||||
|
||||
var fn;
|
||||
setTimeout(function () {
|
||||
// this is just a hack to give `6to5-minify` and other files including this
|
||||
// time to modify `exports.opts`
|
||||
|
||||
if (commander.outDir) {
|
||||
fn = require("./dir");
|
||||
} else {
|
||||
fn = require("./file");
|
||||
}
|
||||
var fn;
|
||||
|
||||
fn(commander, filenames, exports.opts);
|
||||
if (commander.outDir) {
|
||||
fn = require("./dir");
|
||||
} else {
|
||||
fn = require("./file");
|
||||
}
|
||||
|
||||
fn(commander, filenames, exports.opts);
|
||||
}, 0);
|
||||
|
||||
Reference in New Issue
Block a user