json
json copied to clipboard
How to reverse `--items` back to object form? (filter sub-objects)
Am I missing something or is there no way to reverse --items
? Say something like
$ cat object.json | json --items -c 'this.value.battles > 2' | json --to-object
Where the output would have the same object shape as the input, just filtered out some of the key-value pairs.