Closed as not planned
Description
Problem
Some users may want to have additional format options for CLI output for easier reading or data usage or testing, such as json or table output.
Definition of Done
We should allow CLI users to specify a different format for the output for non-interactive uses. The immediate use case is testing, but I think it would be good for users as well. I propose we use --format=json
. An alternative is --json
, but that's a little less forward-compatible with other formats in the future. An open question is whether we allow use of this format when someone is interactively typing in inputs. I don't have a strong feeling about it; I'm open to other people's stronger feelings or just whatever is easiest.
Acceptance Criteria
- New optional global flag on all CLI commands called
--output
(shorthand-o
) with available values"table"
and"json"
. - When the flag is specified, the output format should match the flag if the command supports it
- Some commands won't support the output flag because they don't really output anything other than a "success" message, like
login
- Some commands won't support the output flag because they don't really output anything other than a "success" message, like
- Ensure that no errors/log statements are being written to stdout, they should only be written to stderr
- Ensure that no output is being written to stderr, they should only be written to stdout