Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Don't minify vendored uglify source

  • Loading branch information...
commit f058937b346a3cbfbfa92c4b16949e350b73c43a 1 parent 76d5e3c
@josh josh authored
Showing with 7 additions and 12 deletions.
  1. +7 −12 build.js
View
19 build.js
@@ -1,9 +1,7 @@
#!/usr/bin/env node
-var fs = require("fs");
-var stitch = require("stitch");
-var UglifyJS = require("./vendor/uglifyjs");
-var uglify = UglifyJS.uglify;
+var fs = require("fs");
+var stitch = require("stitch");
var package = stitch.createPackage({
paths: [__dirname + "/vendor/uglifyjs/lib"]
@@ -13,14 +11,11 @@ package.compile(function(err, source) {
if (err) throw err;
source = "(function(global) {" +
- source + ";" +
- "global.UglifyJS = {};" +
- "global.UglifyJS.parser = this.require('parse-js');" +
- "global.UglifyJS.uglify = this.require('process');" +
- "}).call({}, this)";
-
- var ast = UglifyJS.parser.parse(source);
- source = uglify.gen_code(uglify.ast_squeeze(uglify.ast_mangle(ast)));
+ source + ";\n" +
+ "global.UglifyJS = {};\n" +
+ "global.UglifyJS.parser = this.require('parse-js');\n" +
+ "global.UglifyJS.uglify = this.require('process');\n" +
+ "}).call({}, this);\n";
fs.writeFile(__dirname + "/lib/uglify.js", source, function(err) {
if (err) throw err;
Please sign in to comment.
Something went wrong with that request. Please try again.