Skip to content

Commit

Permalink
Merge pull request jsdoc#1106 from tschaub/four
Browse files Browse the repository at this point in the history
Remove Mozilla Rhino support
  • Loading branch information
hegemonic committed Nov 2, 2015
2 parents 9cb7302 + 621f012 commit e2fd9e7
Show file tree
Hide file tree
Showing 176 changed files with 167 additions and 38,442 deletions.
2 changes: 0 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
node_modules/*
rhino/*
templates/default/static/scripts/*
test/fixtures/*
test/lib/*
Expand Down
16 changes: 1 addition & 15 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,21 +1,7 @@
# Development-related files
.tern-port
coverage/
node_modules/.bin
node_modules/eslint
node_modules/gulp*
node_modules/istanbul

# Node.js-only modules
node_modules/requizzle

# Unused files from committed modules
node_modules/bluebird/README.md
node_modules/bluebird/changelog.md
node_modules/bluebird/js/browser/*
node_modules/espree/README.md
node_modules/espree/bin
node_modules/espree/test
/node_modules/

# User-specific files
conf.json
Expand Down
7 changes: 0 additions & 7 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,4 @@
.gitignore
.travis.yml
gulpfile.js

# scripts for launching JSDoc with Mozilla Rhino
/jsdoc*
!/jsdoc.js

# Rhino and test directories
rhino/
test/
83 changes: 0 additions & 83 deletions LICENSE.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,19 +145,6 @@ Copyright (c) 2011-2015 by the Espree contributors.
The source code for Esprima is available at:
https://github.com/eslint/espree

## events ##

Portions of the events source code are incorporated into the following files:

+ `rhino/events.js`

events is distributed under the MIT license, which is reproduced above.

Copyright Joyent, Inc. and other Node contributors. All rights reserved.

The source code for events is available at:
https://github.com/Gozala/events

## github-flavored-markdown ##

github-flavored-markdown is distributed under the BSD 3-clause license:
Expand Down Expand Up @@ -234,36 +221,6 @@ Copyright (c) 2012 Michael Kourlas.
The source code for js2xmlparser is available at:
https://github.com/michaelkourlas/node-js2xmlparser

## Node.js ##

Portions of the Node.js source code are incorporated into the following files:

- `rhino/fs.js`
- `rhino/path.js`
- `rhino/querystring.js`
- `rhino/util.js`

Node.js is distributed under the MIT license, which is reproduced above.

Copyright Joyent, Inc. and other Node contributors. All rights reserved.

The source code for Node.js is available at:
https://github.com/joyent/node

## node-browser-builtins ##

Portions of the node-browser-builtins source code are incorporated into the
following files:

- `rhino/assert.js`
- `rhino/rhino-shim.js`

node-browser-builtins is distributed under the MIT license, which is reproduced
above.

The source code for node-browser-builtins is available at:
https://github.com/alexgorbatchev/node-browser-builtins

## Open Sans ##

Open Sans is distributed under the Apache License 2.0, which is
Expand All @@ -284,46 +241,6 @@ Copyright (c) 2012-2013 Johannes Ewald.
The source code for Requizzle is available at:
https://github.com/hegemonic/requizzle

## Rhino ##

Rhino is distributed under the following licenses:

### MPL 2.0 License ###
The majority of the source code for Rhino is available under the Mozilla Public
License (MPL) 2.0, which is included in this distribution.

### License for portions of the Rhino debugger ###
Additionally, some files are available under the BSD 3-clause license:

> Copyright 1997, 1998 Sun Microsystems, Inc. All Rights Reserved.
>
> Redistribution and use in source and binary forms, with or without
> modification, are permitted provided that the following conditions are met:
>
> - Redistributions of source code must retain the above copyright notice,
> this list of conditions and the following disclaimer.
> - Redistributions in binary form must reproduce the above copyright
> notice, this list of conditions and the following disclaimer in the
> documentation and/or other materials provided with the distribution.
> - Neither the name of Sun Microsystems nor the names of its contributors
> may be used to endorse or promote products derived from this software
> without specific prior written permission.
>
> THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
> AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
> IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
> DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
> FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
> DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
> SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
> CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
> OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
> OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
### Source Code ###
The source code for Rhino is available at:
https://github.com/jsdoc3/rhino

## TaffyDB ##

TaffyDB is distributed under a modified BSD license:
Expand Down
56 changes: 2 additions & 54 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,8 @@ Want to contribute to JSDoc? Please read `CONTRIBUTING.md`.
Installation and Usage
----------------------

You can run JSDoc on either Node.js or Mozilla Rhino.

### Node.js

Native support for Node.js is available in JSDoc 3.3.0 and later. JSDoc
supports Node.js 0.10 and later.

#### Installing JSDoc for Node.js

You can install JSDoc in your project's `node_modules` folder, or you can
install it globally.
JSDoc supports Node.js 0.10 and later. You can install JSDoc in your project's
`node_modules` folder, or you can install it globally.

To install the latest version available on NPM:

Expand All @@ -29,8 +20,6 @@ To install the latest development version:

npm install git+https://github.com/jsdoc3/jsdoc.git

#### Running JSDoc with Node.js

If you installed JSDoc locally, the JSDoc command-line tool is available in
`./node_modules/.bin`. To generate documentation for the file
`yourJavaScriptFile.js`:
Expand All @@ -46,47 +35,6 @@ can use the `--destination` (`-d`) option to specify another directory.

Run `jsdoc --help` for a complete list of command-line options.

### Mozilla Rhino

All versions of JSDoc 3 run on a customized version of Mozilla Rhino, which
requires Java. You can run JSDoc 3 on Java 1.6 and later.

#### Installing JSDoc for Mozilla Rhino

To install JSDoc, download a .zip file for the
[latest development version](https://github.com/jsdoc3/jsdoc/archive/master.zip)
or a [previous release](https://github.com/jsdoc3/jsdoc/tags).

You can also use git to clone the
[JSDoc repository](https://github.com/jsdoc3/jsdoc):

git clone git+https://github.com/jsdoc3/jsdoc.git

The JSDoc repository includes a
[customized version of Mozilla Rhino](https://github.com/jsdoc3/rhino). Make
sure your Java classpath does not include any other versions of Rhino. (On OS X,
you may need to remove the file `~/Library/Java/Extensions/js.jar`.)

**Note**: In JSDoc 3.3.0 and later, if you need to run JSDoc on Mozilla Rhino,
do not install JSDoc with npm. Use one of the methods described above.

#### Running JSDoc with Mozilla Rhino

On OS X, Linux, and other POSIX systems, to generate documentation for the file
`yourJavaScriptFile.js`:

./jsdoc yourJavaScriptFile.js

Or on Windows:

jsdoc yourJavaScriptFile.js

By default, the generated documentation is saved in a directory named `out`. You
can use the `--destination` (`-d`) option to specify another directory.

Run `jsdoc --help` for a complete list of command-line options.


Templates and Build Tools
-------------------------

Expand Down
5 changes: 1 addition & 4 deletions cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,7 @@
* A few critical notes for anyone who works on this module:
*
* + The module should really export an instance of `cli`, and `props` should be properties of a
* `cli` instance. However, Rhino interpreted `this` as a reference to `global` within the
* prototype's methods, so we couldn't do that.
* + On Rhino, for unknown reasons, the `jsdoc/fs` and `jsdoc/path` modules can fail in some cases
* when they are required by this module. You may need to use `fs` and `path` instead.
* `cli` instance.
*
* @private
*/
Expand Down
24 changes: 2 additions & 22 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,7 @@ var options = {
'test/specs/**/*.js'
],
nodeBin: path.resolve(__dirname, './jsdoc.js'),
nodePath: process.execPath,
rhinoBin: (function() {
var filepath = path.resolve(__dirname, './jsdoc');

if (os.platform().indexOf('win') === 0) {
filepath += '.cmd';
}

return filepath;
})()
nodePath: process.execPath
};

gulp.task('bump', function() {
Expand All @@ -63,20 +54,9 @@ gulp.task('lint', function() {
.pipe(eslint.failOnError());
});

gulp.task('test-node', function(cb) {
gulp.task('test', function(cb) {
var cmd = util.format('%s "%s" -T', options.nodePath, options.nodeBin);
exec(cmd, execCb.bind(null, cb));
});

gulp.task('test-rhino', function(cb) {
var cmd = util.format('"%s" -T -q "parser=rhino"', options.rhinoBin);
exec(cmd, execCb.bind(null, cb));
});

gulp.task('test-rhino-jsparser', function(cb) {
var cmd = util.format('"%s" -T -q "parser=js"', options.rhinoBin);
exec(cmd, execCb.bind(null, cb));
});

gulp.task('test', ['test-node', 'test-rhino', 'test-rhino-jsparser']);
gulp.task('default', ['lint', 'test']);
33 changes: 0 additions & 33 deletions jsdoc

This file was deleted.

26 changes: 0 additions & 26 deletions jsdoc.cmd

This file was deleted.

Loading

0 comments on commit e2fd9e7

Please sign in to comment.