tplant
tplant copied to clipboard
Add support for an !include file (optional) that would have settings
I want to use this in a CI on Github to create PlantUML documentation of my API. But I don't want to see all the methods or attributes in the diagrams.
I'd like to insert a line hide members
. But maybe I also want to hide circle
or other customizations. I don't want to hack something with sed
(but I will probably end up doing that).
It would be cool if tplant had an option -config <includefile>
that would include the file just after the @startuml
that is generated.
@fuhrmanator this tool is proving popular. Problem is I don't use plantuml that often and I am not too familiar with it. Can you provide sample input, output, and how you would provide the option?
Here's an example (the tplant tool would have to generate the !include
line):
@startuml
!include customizations.puml
...
@enduml
A customizations.puml
could be like:
hide members
skinparam style strictuml
So, the command could be tplant --customizations customizations.puml ...
Basically, it's an optional hook to allow custom plantuml commands (any) from a specified file to be inserted after the line of @startuml
. PlantUML has the !include
feature already; tplant just has to write that one line (it doesn't need to even check if the file exists).
Makes sense to me. I may try to get PR ready for this but have limited time over next few weeks.
Nothing urgent! I hacked a solution on my CI, if you're curious:
https://github.com/fuhrmanator/FamixTypeScriptImporter/blob/acb4c04d488a87ed67f74e082f81333633b11255/.github/workflows/node.js.yml#L38-L43