2017 © Pedro Peláez
 

wordpress-plugin wp-phpdoc-markdown

Create markdown from WordPress phpdoc, focused on hooks (action/filter). Forked from https://github.com/WordPress/phpdoc-parser

image

pentatonicfunk/wp-phpdoc-markdown

Create markdown from WordPress phpdoc, focused on hooks (action/filter). Forked from https://github.com/WordPress/phpdoc-parser

  • Friday, May 11, 2018
  • by pentatonicfunk
  • Repository
  • 2 Watchers
  • 0 Stars
  • 0 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 4 Open issues
  • 4 Versions
  • 0 % Grown

The README.md

WP phpDoc Markdown

Create Markdown documentations for WordPress Code. Currently its only creating docs for hooks. Functions and Classes not included yet., (*1)

History and Credits

This project is based on WordPress/phpdoc-parser., (*2)

Inline documentation should follow WordPress Best Practices, (*3)

Sample Output : example.md

Requirements

Clone the repository into your WordPress plugins directory:, (*4)

git clone git@github.com:pentatonicfunk/wp-phpdoc-markdown.git 

After that install the dependencies using composer in the parser directory:, (*5)

composer install

Running

Activate the plugin first:, (*6)

wp plugin activate wp-phpdoc-markdown

In your site's directory / wp-phpdoc-markdown directory:, (*7)

wp wparser mdhooks <src_dir> <output_dir> [--json_doc=<json_doc>]
wp wparser mdhooks ../forminator/ ./../forminator/docs

Customization

All default used templates are placed in templates, (*8)

To Customize it define this constant in your wp-config.php, (*9)

define( 'WP_PHPDOC_MARKDOWN_TEMPLATE_TOC', '/path/to/toc.md' );
define( 'WP_PHPDOC_MARKDOWN_TEMPLATE_HOOK', __DIR__ . '/path/to/hook.md' );
define( 'WP_PHPDOC_MARKDOWN_TEMPLATE_HOOK_PARAMETERS', '/path/to/hook.parameters.md' );
define( 'WP_PHPDOC_MARKDOWN_TEMPLATE_HOOK_PARAMETER', '/path/to/hook.parameter.md' );
define( 'WP_PHPDOC_MARKDOWN_TEMPLATE_HOOK_CHANGELOGS', '/path/to/hook.changelogs.md' );
define( 'WP_PHPDOC_MARKDOWN_TEMPLATE_HOOK_CHANGELOG', '/path/to/hook.changelog.md' );

Usage Help

NAME

wp wparser mdhooks

DESCRIPTION

Generate a JSON file containing the PHPDoc markup, and create markdown docs of hooks on <output_dir>.

SYNOPSIS

wp wparser mdhooks <src_dir> <output_dir> [--json_doc=<json_doc>]

OPTIONS

<src_dir>
    Source code directory

<output_dir>
    Desired Output directory of markdown documents

[--json_doc=<json_doc>]
    Where temporary generated json phpdoc will be created, default is /tmp/phpdoc.json

EXAMPLES

wp wparser mdhooks <src_dir> <output_dir> [--json_doc=<json_doc>]
wp wparser mdhooks ../forminator/ ./../forminator/docs --json_doc=/tmp/phpdoc.json

The Versions

11/05 2018

dev-master

9999999-dev https://github.com/pentatonicfunk/wp-phpdoc-markdown

Create markdown from WordPress phpdoc, focused on hooks (action/filter). Forked from https://github.com/WordPress/phpdoc-parser

  Sources   Download

GPL-2.0-or-later

The Requires

 

wordpress markdown hooks

11/05 2018

dev-type-hinting

dev-type-hinting https://github.com/pentatonicfunk/wp-phpdoc-markdown

Create markdown from WordPress phpdoc, focused on hooks (action/filter). Forked from https://github.com/WordPress/phpdoc-parser

  Sources   Download

GPL-2.0-or-later

The Requires

 

wordpress markdown hooks

11/05 2018

dev-pentatonicfunk-issue-template

dev-pentatonicfunk-issue-template https://github.com/pentatonicfunk/wp-phpdoc-markdown

Create markdown from WordPress phpdoc, focused on hooks (action/filter). Forked from https://github.com/WordPress/phpdoc-parser

  Sources   Download

GPL-2.0-or-later

The Requires

 

wordpress markdown hooks

11/05 2018

dev-func-rename

dev-func-rename https://github.com/pentatonicfunk/wp-phpdoc-markdown

Create markdown from WordPress phpdoc, focused on hooks (action/filter). Forked from https://github.com/WordPress/phpdoc-parser

  Sources   Download

GPL-2.0-or-later

The Requires

 

wordpress markdown hooks