chevdor/subwasm

Make the --json flag global

chevdor opened this issue · 2 comments

While it logically makes sense to have a global --json flag, it is rather inconvenient.

As a user, it is common to play around not using json output and switching later on.

So the test command could be:

subwasm meta <args>

Currently, to get the result as json, the user needs to "go back" and stick a --json before the subcommand:

subwasm --json meta <args>

It would be convenient to also support it in the commands:

subwasm meta <args> --json

That allows people simply sticking a -j at the end of the command.

Or better make sub commands inherit from the main ones.

What can be done using global.