--option flag1,flag2
Another possibility is to make the main option an argument, like the subcommands in git, systemctl, and others:
command option --flag1 --flag2
Embedding a second parse step that the first parser doesn't deal with is done, but it's a rough compromise.
It feels like the difficulty in dealing with
[--option [--flag1 --flag2]]
Another possibility is to make the main option an argument, like the subcommands in git, systemctl, and others:
This depends on the specifics, though.