Skip to content

Commit

Permalink
adds new lines and fixes getjs
Browse files Browse the repository at this point in the history
  • Loading branch information
justinbmeyer committed Sep 21, 2011
1 parent 2fc0746 commit 2b8e332
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions generate/generate.js
Expand Up @@ -163,7 +163,7 @@ steal("steal/generate/ejs.js", 'steal/generate/inflector.js',
} else if(!/^\.\w+$/.test(name)){

//create file
steal.print(' ' + where + "/" + convert);
//steal.print(' ' + where + "/" + convert);
new steal.File(where + "/" + convert).mkdirs();

//recurse in new folder
Expand Down Expand Up @@ -258,7 +258,7 @@ steal("steal/generate/ejs.js", 'steal/generate/inflector.js',
* @param {String} destination a path to the script we're inserting a steal into
* @param {String} newStealPath the new steal path to be inserted
*/
insertSteal: function( destination, newStealPath ){
insertSteal: function( destination, newStealPath, newline ){
// get file, parse it
var fileTxt = readFile(destination),
parser = steal.parse(fileTxt),
Expand Down Expand Up @@ -289,7 +289,7 @@ steal("steal/generate/ejs.js", 'steal/generate/inflector.js',
// insert steal
if(lastToken){
fileTxt = fileTxt.slice(0, lastToken.from)
+ "'" + newStealPath + "', " + fileTxt.slice(lastToken.from)
+ "'" + newStealPath + "'," +(newline ? "\n\t" : " ") + fileTxt.slice(lastToken.from)
} else { // no steal found
fileTxt += "steal('" + newStealPath +"')"
}
Expand Down
2 changes: 1 addition & 1 deletion getjs
@@ -1,4 +1,4 @@
load("steal/rhino/steal.js");
load("steal/rhino/rhino.js");
steal('//steal/get/get', function () {
var url = _args.shift();
steal.get(url, _args);
Expand Down

0 comments on commit 2b8e332

Please sign in to comment.