2025-05-08 12:26:01 -06:00
|
|
|
# jc
|
|
|
|
|
|
|
|
|
|
> Convert the output of multiple commands to JSON.
|
2026-02-18 06:55:01 -07:00
|
|
|
> More information: <https://github.com/kellyjonbrazil/jc#usage>.
|
2025-05-08 12:26:01 -06:00
|
|
|
|
|
|
|
|
- Convert command output to JSON via pipe:
|
|
|
|
|
|
|
|
|
|
`{{ifconfig}} | jc {{--ifconfig}}`
|
|
|
|
|
|
|
|
|
|
- Convert command output to JSON via magic syntax:
|
|
|
|
|
|
|
|
|
|
`jc {{ifconfig}}`
|
|
|
|
|
|
|
|
|
|
- Output pretty JSON via pipe:
|
|
|
|
|
|
|
|
|
|
`{{ifconfig}} | jc {{--ifconfig}} {{[-p|--pretty]}}`
|
|
|
|
|
|
|
|
|
|
- Output pretty JSON via magic syntax:
|
|
|
|
|
|
|
|
|
|
`jc {{[-p|--pretty]}} {{ifconfig}}`
|