Recommend this page to a friend! |
Download |
Info | Documentation | Files | Install with Composer | Download | Reputation | Support forum | Blog | Links |
Ratings | Unique User Downloads | Download Rankings | ||||
Not yet rated by the users | Total: 43 | All time: 10,838 This week: 560 |
Version | License | PHP version | Categories | |||
phpdoc-to-rst 1.0.0 | MIT/X Consortium ... | 7 | PHP 5, Tools, Parsers |
Collaborate with this project | Author | |
phpdoc-to-rst - github.com Description This package can generate Sphinx documentation from PHPDoc comments. Innovation Award |
Forked and refactor by Francesco "Abbadon1334" Danti.
Now working as intended, with good coverage.
This project is heavily based on phpDocumentor/Reflection and makes use of sphinxcontrib-phpdomain.
An example for the documentation output can be found in our own documentation
Install phpdoc-to-rst to your project directory:
composer require --dev abbadon1334/phpdoc-to-rst
Run the command line tool to parse the folders containing your PHP tree and render the reStructuredText files to the output directory:
php vendor/bin/phpdoc-to-rst generate --repo-base "$PWD" --repo-github https://github.com/abbadon1334/phpdoc-to-rst -t docs/rst/ src/
// your source path or multiple path to be parsed
$src = [__DIR__.'/../src'];
// destination path for the documentation
$dst = __DIR__.'/../docs/api';
$apiDocBuilder = new ApiDocBuilder($src, $dst);
// DEBUG FATURES : optional
// optional : activate verbosity
$apiDocBuilder->setVerboseOutput(true);
// optional : activate debug
$apiDocBuilder->setDebugOutput(true);
// EXTENSIONS : optional
/
* Do not render classes marked with phpDoc internal tag
* Do only render public methods/properties.
*/
$apiDocBuilder->addExtension(PublicOnlyExtension::class);
/
* Do not render classes marked with phpDoc internal tag
* Do only render public methods/properties.
*/
$apiDocBuilder->addExtension(NoPrivateExtension::class);
/
* This extension will render a list of methods for easy access
* at the beginning of classes, interfaces and traits.
*/
$apiDocBuilder->addExtension(TocExtension::class);
/
* This extension adds a link to the source at github to all elements.
*
* Arguments
* 0 => Url to the github repo (required)
* 1 => Path to the git repository (required)
* 2 => Branch to link to (default=master)
*/
$apiDocBuilder->addExtension(GithubLocationExtension::class, [
__DIR__.'/../src',
'http://github.com/abbadon1334/phpdoc-to-rst/',
]);
// Build documentation
$apiDocBuilder->build();
Files (161) |
File | Role | Description | ||
---|---|---|---|---|
bin (1 file) | ||||
docs (8 files, 4 directories) | ||||
example (1 file) | ||||
src (3 files, 3 directories) | ||||
.readthedocs.yml | Data | Auxiliary data | ||
.travis.yml | Data | Auxiliary data | ||
composer.json | Data | Auxiliary data | ||
LICENSE | Lic. | License text | ||
Makefile | Data | Auxiliary data | ||
phpunit.xml | Data | Auxiliary data | ||
README.md | Doc. | Documentation | ||
renovate.json | Data | Auxiliary data |
Files (161) | / | docs |
File | Role | Description | ||
---|---|---|---|---|
api (2 files, 1 directory) | ||||
_build (1 directory) | ||||
_static (1 file) | ||||
_templates (1 file) | ||||
cli.rst | Data | Auxiliary data | ||
conf.py | Data | Auxiliary data | ||
extensions.rst | Data | Auxiliary data | ||
index.rst | Data | Auxiliary data | ||
make.bat | Data | Auxiliary data | ||
Makefile | Data | Auxiliary data | ||
requirements.txt | Doc. | Documentation | ||
usage.rst | Data | Auxiliary data |
Files (161) | / | docs | / | api |
File | Role | Description | ||
---|---|---|---|---|
JuliusHaertl (1 directory) | ||||
index-namespaces-all.rst | Data | Auxiliary data | ||
index.rst | Data | Auxiliary data |
Files (161) | / | docs | / | api | / | JuliusHaertl | / | PHPDocToRst |
File | Role | Description | ||
---|---|---|---|---|
Builder (10 files) | ||||
Extension (9 files) | ||||
Middleware (2 files) | ||||
ApiDocBuilder.rst | Data | Auxiliary data | ||
GenerateDocumentationCommand.rst | Data | Auxiliary data | ||
index.rst | Data | Auxiliary data | ||
WriteException.rst | Data | Auxiliary data |
Files (161) | / | docs | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Builder |
File | Role | Description |
---|---|---|
ClassFileBuilder.rst | Data | Auxiliary data |
ExtensionBuilder.rst | Data | Auxiliary data |
FileBuilder.rst | Data | Auxiliary data |
index.rst | Data | Auxiliary data |
InterfaceFileBuilder.rst | Data | Auxiliary data |
MainIndexBuilder.rst | Data | Auxiliary data |
NamespaceIndexBuilder.rst | Data | Auxiliary data |
PhpDomainBuilder.rst | Data | Auxiliary data |
RstBuilder.rst | Data | Auxiliary data |
TraitFileBuilder.rst | Data | Auxiliary data |
Files (161) | / | docs | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Extension |
File | Role | Description |
---|---|---|
AddFullElementNameExtension.rst | Data | Auxiliary data |
Extension.rst | Data | Auxiliary data |
GithubLocationExtension.rst | Data | Auxiliary data |
HideChildNamespaces.rst | Data | Auxiliary data |
index.rst | Data | Auxiliary data |
InterfaceImplementors.rst | Data | Auxiliary data |
NoPrivateExtension.rst | Data | Auxiliary data |
PublicOnlyExtension.rst | Data | Auxiliary data |
TocExtension.rst | Data | Auxiliary data |
Files (161) | / | docs | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Middleware |
File | Role | Description |
---|---|---|
ErrorHandlingMiddleware.rst | Data | Auxiliary data |
index.rst | Data | Auxiliary data |
Files (161) | / | docs | / | _build | / | html |
File | Role | Description | ||
---|---|---|---|---|
api (2 files, 1 directory) | ||||
_sources (4 files, 1 directory) | ||||
_static (21 files, 3 directories) | ||||
.buildinfo | Data | Auxiliary data | ||
cli.html | Doc. | Documentation | ||
extensions.html | Doc. | Documentation | ||
genindex.html | Doc. | Documentation | ||
index.html | Doc. | Documentation | ||
php-modindex.html | Doc. | Documentation | ||
search.html | Doc. | Documentation | ||
searchindex.js | Data | Auxiliary data | ||
usage.html | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | api |
File | Role | Description | ||
---|---|---|---|---|
JuliusHaertl (1 directory) | ||||
index-namespaces-all.html | Doc. | Documentation | ||
index.html | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | api | / | JuliusHaertl |
File | Role | Description | ||
---|---|---|---|---|
PHPDocToRst (4 files, 3 directories) |
Files (161) | / | docs | / | _build | / | html | / | api | / | JuliusHaertl | / | PHPDocToRst |
File | Role | Description | ||
---|---|---|---|---|
Builder (10 files) | ||||
Extension (9 files) | ||||
Middleware (2 files) | ||||
ApiDocBuilder.html | Doc. | Documentation | ||
GenerateDocumentationCommand.html | Doc. | Documentation | ||
index.html | Doc. | Documentation | ||
WriteException.html | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Builder |
File | Role | Description |
---|---|---|
ClassFileBuilder.html | Doc. | Documentation |
ExtensionBuilder.html | Doc. | Documentation |
FileBuilder.html | Doc. | Documentation |
index.html | Doc. | Documentation |
InterfaceFileBuilder.html | Doc. | Documentation |
MainIndexBuilder.html | Doc. | Documentation |
NamespaceIndexBuilder.html | Doc. | Documentation |
PhpDomainBuilder.html | Doc. | Documentation |
RstBuilder.html | Doc. | Documentation |
TraitFileBuilder.html | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Extension |
File | Role | Description |
---|---|---|
AddFullElementNameExtension.html | Doc. | Documentation |
Extension.html | Doc. | Documentation |
GithubLocationExtension.html | Doc. | Documentation |
HideChildNamespaces.html | Doc. | Documentation |
index.html | Doc. | Documentation |
InterfaceImplementors.html | Doc. | Documentation |
NoPrivateExtension.html | Doc. | Documentation |
PublicOnlyExtension.html | Doc. | Documentation |
TocExtension.html | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Middleware |
File | Role | Description |
---|---|---|
ErrorHandlingMiddleware.html | Doc. | Documentation |
index.html | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _sources |
File | Role | Description | ||
---|---|---|---|---|
api (2 files, 1 directory) | ||||
cli.rst.txt | Doc. | Documentation | ||
extensions.rst.txt | Doc. | Documentation | ||
index.rst.txt | Doc. | Documentation | ||
usage.rst.txt | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _sources | / | api |
File | Role | Description | ||
---|---|---|---|---|
JuliusHaertl (1 directory) | ||||
index-namespaces-all.rst.txt | Doc. | Documentation | ||
index.rst.txt | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _sources | / | api | / | JuliusHaertl |
File | Role | Description | ||
---|---|---|---|---|
PHPDocToRst (4 files, 3 directories) |
Files (161) | / | docs | / | _build | / | html | / | _sources | / | api | / | JuliusHaertl | / | PHPDocToRst |
File | Role | Description | ||
---|---|---|---|---|
Builder (10 files) | ||||
Extension (9 files) | ||||
Middleware (2 files) | ||||
ApiDocBuilder.rst.txt | Doc. | Documentation | ||
GenerateDocumentationCommand.rst.txt | Doc. | Documentation | ||
index.rst.txt | Doc. | Documentation | ||
WriteException.rst.txt | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _sources | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Builder |
File | Role | Description |
---|---|---|
ClassFileBuilder.rst.txt | Doc. | Documentation |
ExtensionBuilder.rst.txt | Doc. | Documentation |
FileBuilder.rst.txt | Doc. | Documentation |
index.rst.txt | Doc. | Documentation |
InterfaceFileBuilder.rst.txt | Doc. | Documentation |
MainIndexBuilder.rst.txt | Doc. | Documentation |
NamespaceIndexBuilder.rst.txt | Doc. | Documentation |
PhpDomainBuilder.rst.txt | Doc. | Documentation |
RstBuilder.rst.txt | Doc. | Documentation |
TraitFileBuilder.rst.txt | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _sources | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Extension |
File | Role | Description |
---|---|---|
AddFullElementNameExtension.rst.txt | Doc. | Documentation |
Extension.rst.txt | Doc. | Documentation |
GithubLocationExtension.rst.txt | Doc. | Documentation |
HideChildNamespaces.rst.txt | Doc. | Documentation |
index.rst.txt | Doc. | Documentation |
InterfaceImplementors.rst.txt | Doc. | Documentation |
NoPrivateExtension.rst.txt | Doc. | Documentation |
PublicOnlyExtension.rst.txt | Doc. | Documentation |
TocExtension.rst.txt | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _sources | / | api | / | JuliusHaertl | / | PHPDocToRst | / | Middleware |
File | Role | Description |
---|---|---|
ErrorHandlingMiddleware.rst.txt | Doc. | Documentation |
index.rst.txt | Doc. | Documentation |
Files (161) | / | docs | / | _build | / | html | / | _static |
File | Role | Description | ||
---|---|---|---|---|
css (2 files) | ||||
fonts (1 file) | ||||
js (2 files) | ||||
ajax-loader.gif | Icon | Icon image | ||
basic.css | Data | Auxiliary data | ||
comment-bright.png | Icon | Icon image | ||
comment-close.png | Icon | Icon image | ||
comment.png | Icon | Icon image | ||
doctools.js | Data | Auxiliary data | ||
documentation_options.js | Data | Auxiliary data | ||
down-pressed.png | Icon | Icon image | ||
down.png | Icon | Icon image | ||
file.png | Icon | Icon image | ||
jquery.js | Data | Auxiliary data | ||
language_data.js | Data | Auxiliary data | ||
minus.png | Icon | Icon image | ||
plus.png | Icon | Icon image | ||
pygments.css | Data | Auxiliary data | ||
searchtools.js | Data | Auxiliary data | ||
style.css | Data | Auxiliary data | ||
underscore.js | Data | Auxiliary data | ||
up-pressed.png | Icon | Icon image | ||
up.png | Icon | Icon image | ||
websupport.js | Data | Auxiliary data |
Files (161) | / | docs | / | _build | / | html | / | _static | / | css |
File | Role | Description |
---|---|---|
badge_only.css | Data | Auxiliary data |
theme.css | Data | Auxiliary data |
Files (161) | / | docs | / | _build | / | html | / | _static | / | fonts |
File | Role | Description |
---|---|---|
fontawesome-webfont.svg | Data | Auxiliary data |
Files (161) | / | docs | / | _build | / | html | / | _static | / | js |
File | Role | Description |
---|---|---|
modernizr.min.js | Data | Auxiliary data |
theme.js | Data | Auxiliary data |
Files (161) | / | src |
File | Role | Description | ||
---|---|---|---|---|
Builder (9 files) | ||||
Extension (8 files) | ||||
Middleware (1 file) | ||||
ApiDocBuilder.php | Class | Class source | ||
GenerateDocumentationCommand.php | Class | Class source | ||
WriteException.php | Class | Class source |
Files (161) | / | src | / | Builder |
File | Role | Description |
---|---|---|
ClassFileBuilder.php | Class | Class source |
ExtensionBuilder.php | Class | Class source |
FileBuilder.php | Class | Class source |
InterfaceFileBuilder.php | Class | Class source |
MainIndexBuilder.php | Class | Class source |
NamespaceIndexBuilder.php | Class | Class source |
PhpDomainBuilder.php | Class | Class source |
RstBuilder.php | Class | Class source |
TraitFileBuilder.php | Class | Class source |
Files (161) | / | src | / | Extension |
File | Role | Description |
---|---|---|
AddFullElementNameExtension.php | Class | Class source |
Extension.php | Class | Class source |
GithubLocationExtension.php | Class | Class source |
HideChildNamespaces.php | Class | Class source |
InterfaceImplementors.php | Class | Class source |
NoPrivateExtension.php | Class | Class source |
PublicOnlyExtension.php | Class | Class source |
TocExtension.php | Class | Class source |
The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page. |
Install with Composer |
Version Control | Unique User Downloads | Download Rankings | |||||||||||||||
100% |
|
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.