You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
With the addition of structured logging #2576 it's become clear that structured data has user value in outputs not just diagnostic logs. Currently most output, like in zarf package list is printed using pterm tables.
Describe the behavior you'd like
In addition to tables, being able to output json, yaml, or potentially other formats would be hugely valuable for users to script and parse zarf's output. Some utilites like gh and vault provide filtering as well. This allows users to specify only the fields they want in their output, cutting out steps in external tools later. Filtering is more of a nice to have and maybe more appropriate for a second iteration.
@Racer159 Raised the detail that zarf version has an --output / -o flag already and supports rendering to json and yaml. That's a good starting point for us extending this behavior into other commands.
Additional context
This shouldn't be too difficult to implement because, at least as far as I could tell writing this, all of the table printing is well contained to cmd. Swapping out the printer from message, or extracting it into a more configurable layer shouldn't require any significant architecture changes - just pass the data to a new renderer.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
With the addition of structured logging #2576 it's become clear that structured data has user value in outputs not just diagnostic logs. Currently most output, like in
zarf package list
is printed using pterm tables.Describe the behavior you'd like
In addition to tables, being able to output json, yaml, or potentially other formats would be hugely valuable for users to script and parse zarf's output. Some utilites like
gh
andvault
provide filtering as well. This allows users to specify only the fields they want in their output, cutting out steps in external tools later. Filtering is more of a nice to have and maybe more appropriate for a second iteration.@Racer159 Raised the detail that
zarf version
has an--output / -o flag
already and supports rendering to json and yaml. That's a good starting point for us extending this behavior into other commands.Additional context
This shouldn't be too difficult to implement because, at least as far as I could tell writing this, all of the table printing is well contained to
cmd
. Swapping out the printer from message, or extracting it into a more configurable layer shouldn't require any significant architecture changes - just pass the data to a new renderer.The text was updated successfully, but these errors were encountered: