{ "name": "test1", "flags": [ { "forms": [ "-h", "--h" ], "desc": "Show help information" }, { "forms": [ "-v", "--verbose", "--loud" ], "desc": "Verbose output" } ], "subcommands": [ { "name": "sub1", "flags": [ { "forms": [ "--foobar" ], "desc": "Something something [brackets]" } ], "subcommands": [ { "name": "nested", "flags": [ { "forms": [ "-co", "--command", "--another-invalid-flag?!" ], "desc": "Run a command or something" }, { "forms": [ "--install" ], "desc": "Install a thing" } ], "subcommands": [] } ] }, { "name": "sub2", "flags": [ { "forms": [ "--a", "--all" ], "desc": "Both options should be picked up even though the short one is weird" }, { "forms": [ "-C", "--backupdir" ], "desc": "The short form should be picked up as -C, not -Cdirectory (example from nano)" } ], "subcommands": [] } ] }