forked from jsdoc/jsdoc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
jsdoc.cmd
26 lines (20 loc) · 869 Bytes
/
jsdoc.cmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
@ECHO OFF
SETLOCAL
REM jsdoc.js expects paths without a trailing slash
SET _BASEPATH=%~dp0
SET _BASEPATH=%_BASEPATH:~0,-1%
REM we need the ability to resolve paths relative to the user's working
REM directory prior to launching JSDoc
SET PWD=%cd%
IF [%1]==[--debug] (
SET CMD=org.mozilla.javascript.tools.debugger.Main -debug -opt -1
) ELSE (
SET CMD=org.mozilla.javascript.tools.shell.Main
)
SET ARGS=%*
IF [%1]==[-T] (
java -classpath "%_BASEPATH%/rhino/js.jar" %CMD% -opt -1 -modules "%_BASEPATH%/lib" -modules "%_BASEPATH%/node_modules" -modules "%_BASEPATH%/rhino" -modules "%_BASEPATH%" "%_BASEPATH%/jsdoc.js" %ARGS% --nocolor
) ELSE (
java -classpath "%_BASEPATH%/rhino/js.jar" %CMD% -modules "%_BASEPATH%/lib" -modules "%_BASEPATH%/node_modules" -modules "%_BASEPATH%/rhino" -modules "%_BASEPATH%" "%_BASEPATH%/jsdoc.js" %ARGS%
)
ENDLOCAL