jsdoc3/jsdoc — pull request #182 by BobKerns (2012-09-12 02:06:44+00:00)
Title: Make jsdoc script work with MinGW and Cygwin

On MinGW and Cygwin, we have different representations for pathnames,
neither of which Rhino understands. We also have to contend with '\',
which is not a legal URI character.

And we have to supply a third / after file:// (two before the null
hostname, and one before the start of the absolute path). Since Windows
paths don't start with /, we have to supply it in that case.

We handle the MinGW and Cygwin cases by asking for the information with
'pwd -W' for MinGW and 'cygpath $(pwd)' for Cygwin, before finally
falling back to pwd for everyone else. Then, if they don't start with '/'
we supply the extra '/' for the URL.