cvuorinen / phpdoc-md
0.1.2
2015-11-12 20:16 UTC
Requires
- php: >=5.3.1
- twig/twig: ~1.18.0
Requires (Dev)
- phpdocumentor/phpdocumentor: ~2.8.0
README
这是一个脚本,可以从您的 DocBlock 注释中生成 markdown (.md) 文档文件。
此工具针对使用 PSR-0、PSR-1、PSR-2、PSR-4 和命名空间的项目的定制。
此工具基于 Evert Pot 在 https://github.com/evert/phpdoc-md 的作品。
注意! 此包已被 https://github.com/cvuorinen/phpdoc-markdown-public 取代。
安装
使用 composer 安装
composer require cvuorinen/phpdoc-md
使用方法
首先确保 phpDocumentor 2 已安装,之后,您必须生成一个名为 structure.xml
的文件。
最简单的方法是创建一个临时目录,例如命名为 docs/
。
# phpdoc command
phpdoc -d [project path] -t docs/ --template="xml"
# Next, run phpdocmd:
phpdocmd docs/structure.xml [outputdir]
选项
--lt [template]
This specifies the 'template' for links we're generating. By default
this is "%c.md".
--title [title]
This specifies the title for the generated Markdown document.