This captures stacks from anything that throws at a more granular level.
For example, @paulathevalley 's syntax error in init.js now points us to the _lazyRequire() import function specifically within the async.auto.init workflow function, and I've added an extra message adjustment to help a bit more so we get:
$ builder-init $(pwd)/temp-archetype/
temp-archetype-1.0.0.tgz
SyntaxError: Unexpected token }
[builder-init] Error when importing 'temp-archetype/init.js'
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:414:25)
at Object.Module._extensions..js (module.js:442:10)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:313:12)
at Module.require (module.js:366:17)
at require (module.js:385:17)
at Task._lazyRequire (/Users/rroemer/scm/fmd/builder-init/lib/task.js:120:10)
at Array.async.auto.init (/Users/rroemer/scm/fmd/builder-init/lib/task.js:223:21)
at listener (/Users/rroemer/scm/fmd/builder-init/node_modules/async/lib/async.js:605:42)
An alternate approach to https://github.com/FormidableLabs/builder-init/pull/24
This captures stacks from anything that throws at a more granular level.
For example, @paulathevalley 's syntax error in
init.js
now points us to the_lazyRequire()
import function specifically within theasync.auto.init
workflow function, and I've added an extramessage
adjustment to help a bit more so we get:/cc @coopy @paulathevalley