Skip to content

Commit 26d68e3

Browse files
committed
Dynamically resolve jsdoc when running pbts, fixes #622
1 parent 69c04d7 commit 26d68e3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cli/pbts.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ exports.main = function(args, callback) {
9797
// There is no proper API for jsdoc, so this executes the CLI and pipes the output
9898
var basedir = path.join(__dirname, "..");
9999
var moduleName = argv.name || "null";
100-
var cmd = "node \"" + basedir + "/node_modules/jsdoc/jsdoc.js\" -c \"" + basedir + "/jsdoc.types.json\" -q \"module=" + encodeURIComponent(moduleName) + "&comments=" + Boolean(argv.comments) + "\" " + files.map(function(file) { return '"' + file + '"'; }).join(' ');
100+
var cmd = "node \"" + require.resolve("jsdoc/jsdoc.js") + "\" -c \"" + path.join(basedir, "jsdoc.types.json") + "\" -q \"module=" + encodeURIComponent(moduleName) + "&comments=" + Boolean(argv.comments) + "\" " + files.map(function(file) { return "\"" + file + "\""; }).join(" ");
101101
var child = child_process.exec(cmd, {
102102
cwd: process.cwd(),
103103
argv0: "node",

0 commit comments

Comments
 (0)