question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Should CLI Support Per-Command Default Output Formats?

See original GitHub issue

On my machine when I execute ‘az account list’ the result will be returned as JSON but not as list of accounts.

Python (Darwin) 2.7.10 (default, Jul 30 2016, 19:40:32) 
[GCC 4.2.1 Compatible Apple LLVM 8.0.0 (clang-800.0.34)]

I tried some other options to and always get JSON.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
tjprescottcommented, Mar 13, 2017

@StfBauer the default output format applies uniformly to all commands within the CLI. The default output format is set at the user level. There is no concept of per-command default output format (either user or dev configured) in the CLI at this time.

0reactions
derekbekoecommented, Apr 19, 2018

I think this issue can be closed as there are several ways to set the default output type (e.g. az configure or export AZURE_CORE_OUTPUT=table.

Supporting per-command default outputs could just confuse users further.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Setting the AWS CLI output format - AWS Documentation
This topic describes the different output formats for the AWS Command Line Interface (AWS CLI). The AWS CLI supports the following output formats:...
Read more >
Output formats for Azure CLI commands - Microsoft Learn
The Azure CLI uses JSON as its default output format, but offers other formats. Use the --output ( --out or -o ) parameter...
Read more >
picocli - a mighty tiny command line interface
From picocli 4.3, an entry for -- can be shown in the options list of the usage help message of a command with...
Read more >
EdgeSwitch CLI Command Reference - Ubiquiti
Using CLI Help . ... You can enter the IP address in the following formats: ... arguments to filter the CLI output to...
Read more >
[PATCH 1/7] cli: Framework for structured output versioning - notmuch
Previous message: [PATCH 0/7] Structed output versioning support ... Since the caller requests a format version, it's also possible for the CLI to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found