mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-04 17:07:49 +00:00
Merge pull request #2 from bestiejs/autominification
lodash: Make build.js automatically choose the best minification, Uglify or Closure Compiler, and use it for lodash.min.js. [jddalton, kitcambridge] Former-commit-id: fb6fd67dc97d8ac379a580e15cd430593d88966c
This commit is contained in:
@@ -39,9 +39,9 @@
|
||||
if (module != require.main) {
|
||||
module.exports = postprocess;
|
||||
} else {
|
||||
// Read the JavaScript source file from the first argument if the script
|
||||
// read the JavaScript source file from the first argument if the script
|
||||
// was invoked directly (e.g. `node post-compile.js source.js`) and write to
|
||||
// the same file.
|
||||
// the same file
|
||||
(function() {
|
||||
var source = fs.readFileSync(process.argv[2], 'utf8');
|
||||
fs.writeFileSync(process.argv[2], postprocess(source), 'utf8');
|
||||
|
||||
@@ -199,9 +199,9 @@
|
||||
if (module != require.main) {
|
||||
module.exports = preprocess;
|
||||
} else {
|
||||
// Read the JavaScript source file from the first argument if the script
|
||||
// read the JavaScript source file from the first argument if the script
|
||||
// was invoked directly (e.g. `node pre-compile.js source.js`) and write to
|
||||
// the same file.
|
||||
// the same file
|
||||
(function() {
|
||||
var source = fs.readFileSync(process.argv[2], 'utf8');
|
||||
fs.writeFileSync(process.argv[2], preprocess(source), 'utf8');
|
||||
|
||||
Reference in New Issue
Block a user