krampstudio/grunt-jsdoc

Unable to locate jsdoc

jkissel opened this issue · 2 comments

I still get this error, because my project structure forces me to load the task from another location than the current one (via loadTasks("path/to/jsdoc-contrib")).

The task tries to resolve jsdoc based on the current path (cwd) and not from the script location (__dirname).

Changing the line

var base = 'node_modules/jsdoc/jsdoc',

to

var base = __dirname + '/../node_modules/jsdoc/jsdoc',

would fix this issue.

Humm, I'll think how to specify the jsdoc path as an option. I don't like the option relative to the task. I'll let you know.
Thanks for the report

You can set the jsdoc path as an option into your Gruntfile since 0.2.4