jmespath.terminal icon indicating copy to clipboard operation
jmespath.terminal copied to clipboard

Accept yaml file as input

Open filipenf opened this issue 3 years ago • 1 comments

Allows loading yaml files as well as json from the command line. I tested a few cases of loading json/yaml with:

jpterm -y yaml-file.yaml
jpterm -y json-file.json

and even

jpterm -y json-file.json

works as the yaml library can load json format as well

Tested with a few different combinations of json and yaml files - both on stdin and passing the file path as an argument

$ cat test.yml 
---
name: value
list:
  - item 1
  - item 2
dict:
  a: 1
  b: 2
  c: 3

$ jpterm -y test.yml

screen-20201020-1138

filipenf avatar Aug 04 '20 23:08 filipenf