Closed thoughtpalette closed 10 years ago
Just trying to run the default scaffold cmd with grunt scaffold
grunt scaffold
My scaffold.js
module.exports = function ( grunt ) { scaffold: { simple: { options: { template: { "grunt/templates/controller-template.js": "tmp/{{name}}.js" } } }, folders: { options: { template: { "tmp/fixtures/test.js": "tmp/{{name}}.js", "tmp/fixtures/folderA": "tmp/folderA", "tmp/fixtures/folderB": "tmp/folderB" }, filter: function (result) { result.name = "My"; result.priority = "High"; result.severity = "Low"; return result; } } } } }; Error: ```/Users/chrismarshall/Public/Projects/scaffold/vokal-angular-seed/grunt/scaffold.js:24 "grunt/templates/controller-template.js": "tmp/{{name}}.js ^ Loading "Gruntfile.js" tasks...ERROR >> SyntaxError: Unexpected token :```
Looks like the error is due to running module.exports as a function. If it's changed to a plain object, it works as expected. I was originally using the grunt cmds for logging.
Just trying to run the default scaffold cmd with
grunt scaffold
My scaffold.js