oci-cli icon indicating copy to clipboard operation
oci-cli copied to clipboard

Feature request: Simple Output

Open woodcockjosh opened this issue 3 years ago • 3 comments

Both the table output and json output can be very overwhelming for complex data structures. Please add a simplified output for commands. This could be a simplified table view. Putting json inside tables is pretty hard on the eyes.

I would like to see an output type simple added alongside table and json

woodcockjosh avatar May 18 '22 15:05 woodcockjosh

Hi Josh, Could you provide an example?

harshkumar-dev avatar Jun 02 '22 05:06 harshkumar-dev

Something like

Column 1           Column 2         Column 3  
item 1             detail 1         status 1
item 2             detail 2         status 2
item 3             detail 3         status 3

when listing entities

we don't need to put every single attribute in the output. obviously this would have to be tailored to each particular entity as each entity would have something slightly different.

woodcockjosh avatar Jun 02 '22 08:06 woodcockjosh

As you have noted this is challenging because complex data structures can be, uhhm, complex! Some values are too long to reasonably fit in a concise column, and often there are a dozen or more fields. Either of these can lead to a table hundreds of characters wide. Customizing for each resource type may not be practical because the perfect summary for you might not be perfect for others.

Check out how I addressed this with Project O. It has several features to assist with simple output:

  • Automatic selection of a subset of often useful fields
  • EASY selection of custom fields - without jmespath syntax
  • Truncation of long values (left or right trunc) - no wrapping option though
  • Output options: simple table, text, CSV, or unfiltered JSON

Give this a try and let me know what you think.

kevco-us avatar Jul 08 '22 14:07 kevco-us