diff --git a/Makefile.dryice.js b/Makefile.dryice.js index f693d6b2..b508f2f0 100755 --- a/Makefile.dryice.js +++ b/Makefile.dryice.js @@ -34,7 +34,7 @@ * and other provisions required by the GPL or the LGPL. If you do not delete * the provisions above, a recipient may use your version of this file under * the terms of any one of the MPL, the GPL or the LGPL. - * + * * ***** END LICENSE BLOCK ***** */ var fs = require("fs"); @@ -43,7 +43,7 @@ if (!fs.existsSync) var copy = require('dryice').copy; var ACE_HOME = __dirname; -var BUILD_DIR = "build"; +var BUILD_DIR = ACE_HOME + "/build"; function main(args) { var type = "minimal"; @@ -146,16 +146,16 @@ function ace() { console.log('# ace License | Readme | Changelog ---------'); copy({ - source: "build_support/editor.html", - dest: "build/editor.html" + source: ACE_HOME + "/build_support/editor.html", + dest: BUILD_DIR + "/editor.html" }); copy({ source: ACE_HOME + "/LICENSE", - dest: "build/LICENSE" + dest: BUILD_DIR + "/LICENSE" }); copy({ source: ACE_HOME + "/ChangeLog.txt", - dest: "build/ChangeLog.txt" + dest: BUILD_DIR + "/ChangeLog.txt" }); } @@ -164,25 +164,30 @@ function demo() { var version, ref; try { - version = JSON.parse(fs.readFileSync(__dirname + "/package.json")).version; - ref = fs.readFileSync(__dirname + "/.git-ref").toString(); + version = JSON.parse(fs.readFileSync(ACE_HOME + "/package.json")).version; + ref = fs.readFileSync(ACE_HOME + "/.git-ref").toString(); } catch(e) { ref = ""; version = ""; } - var changeComments = function(data) { - return (data - .replace(//g, "") - .replace(/PACKAGE\-\->|/g, "") + .replace(/PACKAGE\-\->|