Metadata-Version: 2.1
Name: textx-dsldoc
Version: 0.0.1
Summary: Autogeneration of DSL documentation for TextX
Home-page: https://github.com/aluriak/textx-dsldoc
Author: Lucas Bourneuf
Author-email: lucas.bourneuf@laposte.net
License: GPL
Keywords: textx subcommand,doc generation
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.5
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Requires-Dist: Click (==7.0)
Requires-Dist: Markdown (==3.0.1)
Requires-Dist: exrex (==0.10.5)
Requires-Dist: textX (==1.9.0)

# TextX DSL autodocumentation tool
A non-official TextX poc-project aiming to autogenerate documentation of DSL.

For testing the TextX integration, you will be required to install [from repository](https://github.com/textX/textX) since the CLI extending is not available in 1.8.


## Files

- [example.py](example.py): example of DSL definition directly taken [from another project](https://github.com/aluriak/24h2019)
- [out.html](out.html): the HTML output file (take a look to get a feeling of the current project achievements)
- [poc.py](poc.py): first implementation, absolutely bad, but few functions are worth saving
- [poc_as_cls.py](poc_as_cls.py): use some functions of `poc.py` to implement the same thing, but in a clearer manner
- [poc_render_peg.py](poc_render_peg.py): rendering of arpeggio (textx backend) grammars

[Current results](out.html) are encouraging.

## F(unny )eatures

- support of docstrings (those at user classes level)
- auto-generation of examples for regexes, and complete linking to [pythex.org](https://pythex.org)


## TODO

- integrate complete example (either randomly or author-provided)
- get a complete example with advanced features like references and other textx/arpeggio constructs
- fix detection and handling of terminal for the description of rules
- generate few examples for each documented rule (randomly, probably)
- make the generation deterministic
- humanize the phrasing (ex: when choice only on raw strings, avoid the bullet list and list them inline directly with an *or* for the last join: *Type either _a_, _b_ or _c_*)
- integration into textx with [textx subcommands](https://github.com/textX/textX/pull/162) (see [doc](http://textx.github.io/textX/latest/textx_command/#extending-textx-command))


