structurizr / cli

A command line utility for Structurizr.
https://docs.structurizr.com/cli
Apache License 2.0
491 stars 75 forks source link

PlantUML subformats missing from CLI help message #29

Closed Berkmann18 closed 3 years ago

Berkmann18 commented 3 years ago

After seeing a weird output on https://structurizr.com/workspace on a project, I looked into exporting my DSL to C4-PlantUML and saw that C4-PlantUML wasn't an option (the PlantUML one isn't suitable for me and seem to be generating something that doesn't look right, maybe a DSL error) although Simon says it is implemented (source: https://twitter.com/simonbrown/status/1363905041078358017?s=20) while I have the latest version at time of writing this (1.8.1).

Am I missing something?

simonbrowndotje commented 3 years ago

The C4-PlantUML export is included in v1.8.1; see Export - options for more details. For example:

./structurizr.sh export -workspace getting-started.dsl -format plantuml/c4plantuml
Structurizr CLI v1.8.1
Exporting workspace from getting-started.dsl
 - loading workspace from DSL
 - writing /Users/simon/Downloads/structurizr-cli-1.8.1/structurizr-SystemContext.puml
 - finished
@startuml(id=SystemContext)
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4.puml
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Context.puml
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Container.puml
!includeurl https://raw.githubusercontent.com/plantuml-stdlib/C4-PlantUML/master/C4_Component.puml
LAYOUT_WITH_LEGEND()

title Software System - System Context
caption An example of a System Context diagram.

Person(1, "User", "A user of my software system.")
System(2, "Software System", "My software system.")
Rel_D(1, 2, "Uses", "")
@enduml

jL5FQ_em6BxdK-JdgSAlBPET1WEBoZQecqpBsAd4zbK3oPkGl4NzzalMUf5TUqfuUFuyJpBt91nrMYMoVTvUFO5U62Iuq9JzazYeheNEANuYilufpvquPqT9fsxVUN1Df29bZT6vLGAZKUgfLNAVBnxJJOIgTPbh4OnTW38R66COrqFhSGE4H71ZHcXh471OKHRV7zMk_dhRlTRbwcNrlaocZ94a1Nnh3dGM3dZ_PpozNOPt

Berkmann18 commented 3 years ago

I see, it's not mentioned in the CLI's help section for export.

Seems like something's wrong with my DSL as well 😕 (unless the system context rendering an "Enterprise" folder and stopping at two levels instead of 3 is normal given the way I did it).

simonbrowndotje commented 3 years ago

It is mentioned...

Screenshot 2021-03-07 at 20 48 12
Berkmann18 commented 3 years ago

Not in the CLI's help section (which I assumed was up-to-date and consistent with the docs, seems like I was wrong and should have checked the docs here): image

Berkmann18 commented 3 years ago

Thank you 😀.