Update readme docs

This commit is contained in:
Jannon 2012-05-06 03:41:04 -07:00
parent a6f68d838c
commit 526a22673a
3 changed files with 43 additions and 10 deletions

View File

@ -72,12 +72,18 @@ JavaScript. Luckily it comes with a full-on debugger included that can be much
more useful than a simple stack trace. To invoke JSDoc with the debugger try the
following command:
jsdoc --debug
or the long form version:
$ java -classpath lib/js.jar \
org.mozilla.javascript.tools.debugger.Main -debug \
-modules node_modules -modules rhino_modules -modules . \
jsdoc.js \
your/script.js
Note: ```--debug``` must be the first argument to the short form command
This will open a debugging window. Choose "Break on Exceptions" from the "Debug"
menu, then press the "Run" button. If there is an error, you should see exactly
where it is in the source code.

View File

@ -341,4 +341,33 @@ doclet to the map (keyed off of the id property) of doclets it knows about.
Lastly, the visitors are executed in the order the plugins are listed in the
conf.json file. A plugin can stop later plugins from visiting a node by
setting a ```stopPropagation``` property on the event object (e.stopPropagation = true).
A plugin can stop the event from firing setting a ```preventDefault``` property.
A plugin can stop the event from firing setting a ```preventDefault``` property.
Packaging JSDoc 3 Plugins
----
The JSDoc 3 Jakefile has an ```install``` task that can be used to install a plugin
into the jsdoc 3 installation. So running the following will install the plugin:
$>jake install[path/to/YourPluginFolder]
_note: on some systems (like MacOS X), you may need to quote the target name and parameters_:
$>jake 'install[path/to/YourPluginFolder]'
The task is passed a directory that should look something like the following:
YourPluginFolder
|- plugins
| |- YourPlugin.js
| \- test
| |- fixtures
| | \- YourFixtures.js
| \- specs
| \- YourTests.js
\- templates
\- YourTemplate
\- publish.js
Basically everything is copied over into the jsdoc installation directory, the
directory should contain anything you want to put there.

View File

@ -15,7 +15,7 @@ and run the following command on Windows:
If you can't get the short-form commands to work, try invoking Java directly:
java -cp lib/js.jar org.mozilla.javascript.tools.shell.Main \
java -cp lib/js.jar org.mozilla.javascript.tools.shell.Main -opt -1 \
-modules node_modules -modules rhino_modules -modules . \
jsdoc.js -T
@ -31,17 +31,15 @@ Take a look at that project's wiki for documentation on writing tests in general
### Tests for JSDoc
And take a look at the files in the ```test``` directory for many examples of
Take a look at the files in the ```test``` directory for many examples of
writing tests for JSDoc itself. the ```test\fixtures``` directory hold fixtures
for use in the tests and the ```test\tests``` directory holds the tests themselves.
for use in the tests and the ```test\specs``` directory holds the tests themselves.
### Tests for plugins
Tests for plugins are found in ```plugins\test``` directory. Plugins containing
tests that were installed with the Jakefile install task will be run automatically.
### Tests for templates
TODO:
More info for contributors about how tests work and about plugin/template tests
TODO