introduced JSDoc: changes for JSDoc compatibility and resolving inconsistencies in documentation, both semantic and in the logic
This commit is contained in:
parent
b06dfa2f07
commit
db2778c64f
|
@ -1,5 +1,5 @@
|
||||||
Generating documentation
|
Generating PHP documentation
|
||||||
========================
|
============================
|
||||||
|
|
||||||
In order to generate the documentation, you will need to install the following
|
In order to generate the documentation, you will need to install the following
|
||||||
packages and its dependencies:
|
packages and its dependencies:
|
||||||
|
@ -12,7 +12,7 @@ can be found in that projects documentation.
|
||||||
|
|
||||||
Example for Debian and Ubuntu:
|
Example for Debian and Ubuntu:
|
||||||
```console
|
```console
|
||||||
$ sudo aptitude install php-pear graphviz
|
$ sudo apt install php-pear graphviz
|
||||||
$ sudo pear channel-discover pear.phpdoc.org
|
$ sudo pear channel-discover pear.phpdoc.org
|
||||||
$ sudo pear install phpdoc/phpDocumentor
|
$ sudo pear install phpdoc/phpDocumentor
|
||||||
```
|
```
|
||||||
|
@ -20,10 +20,41 @@ $ sudo pear install phpdoc/phpDocumentor
|
||||||
To generate the documentation, change into the main directory and run phpdoc:
|
To generate the documentation, change into the main directory and run phpdoc:
|
||||||
```console
|
```console
|
||||||
$ cd PrivateBin
|
$ cd PrivateBin
|
||||||
$ phpdoc -d lib/ -t doc/
|
$ phpdoc -t doc/phpdoc -d lib/
|
||||||
```
|
```
|
||||||
|
|
||||||
**Note:** When used with PHP 7, the prerelease of phpDocumentator 2.9 needs to be
|
**Note:** When used with PHP 7, the prerelease of phpDocumentator 2.9 needs to be
|
||||||
manually installed by downloading it from
|
manually installed by downloading it from
|
||||||
[GitHub](https://github.com/phpDocumentor/phpDocumentor2/releases/download/v2.9.0/phpDocumentor.phar)
|
[GitHub](https://github.com/phpDocumentor/phpDocumentor2/releases/download/v2.9.0/phpDocumentor.phar)
|
||||||
and then manually moving it to e.g. `/usr/local/bin` and making it executable.
|
and then manually moving it to e.g. `/usr/local/bin` and making it executable.
|
||||||
|
|
||||||
|
Generating JS documentation
|
||||||
|
============================
|
||||||
|
|
||||||
|
In order to generate the documentation, you will need to install the following
|
||||||
|
packages and its dependencies:
|
||||||
|
* npm
|
||||||
|
|
||||||
|
Then you can use the node package manager to install the latest stable release
|
||||||
|
of jsdoc globally:
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ npm install -g jsdoc
|
||||||
|
```
|
||||||
|
|
||||||
|
Example for Debian and Ubuntu, including steps to allow current user to install
|
||||||
|
node modules globally:
|
||||||
|
```console
|
||||||
|
$ sudo apt install npm
|
||||||
|
$ sudo mkdir /usr/local/lib/node_modules
|
||||||
|
$ sudo chown -R $(whoami) $(npm config get prefix)/{lib/node_modules,bin,share}
|
||||||
|
$ npm install -g jsdoc
|
||||||
|
$ ln -s /usr/bin/nodejs /usr/local/bin/node
|
||||||
|
```
|
||||||
|
|
||||||
|
To generate the documentation, change into the main directory and run phpdoc:
|
||||||
|
```console
|
||||||
|
$ cd PrivateBin
|
||||||
|
$ jsdoc -d doc/jsdoc js/privatebin.js
|
||||||
|
```
|
||||||
|
|
||||||
|
|
497
js/privatebin.js
497
js/privatebin.js
File diff suppressed because it is too large
Load Diff
|
@ -69,7 +69,7 @@ if ($MARKDOWN):
|
||||||
<?php
|
<?php
|
||||||
endif;
|
endif;
|
||||||
?>
|
?>
|
||||||
<script type="text/javascript" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-eiKDhuH9ab6eBlJbn0nggiYIvCJd82nnzfmr94+NMaSqImQe3V61FKaOwfiBg6AHQCn0GE9OX4xLN5ATfJPGkg==" crossorigin="anonymous"></script>
|
<script type="text/javascript" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-1zupZE5lWp4uoOxMgRfUbLFcTyLl63q8sQAZFEhxWfFmMB0XMgJwbmAhPBOt+haGvNX3ZnzFNUVF6fNB2m+NPw==" crossorigin="anonymous"></script>
|
||||||
<!--[if lt IE 10]>
|
<!--[if lt IE 10]>
|
||||||
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
|
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
|
||||||
<![endif]-->
|
<![endif]-->
|
||||||
|
|
|
@ -47,7 +47,7 @@ if ($MARKDOWN):
|
||||||
<?php
|
<?php
|
||||||
endif;
|
endif;
|
||||||
?>
|
?>
|
||||||
<script type="text/javascript" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-eiKDhuH9ab6eBlJbn0nggiYIvCJd82nnzfmr94+NMaSqImQe3V61FKaOwfiBg6AHQCn0GE9OX4xLN5ATfJPGkg==" crossorigin="anonymous"></script>
|
<script type="text/javascript" src="js/privatebin.js?<?php echo rawurlencode($VERSION); ?>" integrity="sha512-1zupZE5lWp4uoOxMgRfUbLFcTyLl63q8sQAZFEhxWfFmMB0XMgJwbmAhPBOt+haGvNX3ZnzFNUVF6fNB2m+NPw==" crossorigin="anonymous"></script>
|
||||||
<!--[if lt IE 10]>
|
<!--[if lt IE 10]>
|
||||||
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
|
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
|
||||||
<![endif]-->
|
<![endif]-->
|
||||||
|
|
Loading…
Reference in New Issue