mirror of
https://github.com/u1and0/jtr
synced 2026-01-05 06:51:06 +00:00
No description
| .github/workflows | ||
| src | ||
| tests | ||
| .gitignore | ||
| jtr.nimble | ||
| LICENSE | ||
| README.md | ||
Commmand of JSON tree viewer with type.
Example
$ echo '{"foo":5.0,"baz":[{"foo":{"bar":100,"baz":"click","cat":null}}],"login":true}' | jq
{
"foo": 5,
"baz": [
{
"foo": {
"bar": 100,
"baz": "click",
"cat": null
}
}
],
"login": true
}
$ echo '{"foo":5.0,"baz":[{"foo":{"bar":100,"baz":"click","cat":null}}],"login":true}' | jtr
.
├── foo <float>
├── baz [].
│ └── foo
│ ├── bar <int>
│ ├── baz <string>
│ └── cat <null>
└── login <bool>
$ echo '{"foo":5.0,"baz":[{"foo":{"bar":100,"baz":"click","cat":null}}],"login":true}' | jtr '.baz'
[].
└── foo
├── bar <int>
├── baz <string>
└── cat <null>
Installation
$ nimble install jtr
or compile from source
$ git clone https://github.com/u1and0/nim.git
$ cd jtr
$ nim compile -d:release src/jtr.nim
$ sudo ln -s `pwd`/src/jtr /usr/bin
or get from GitHub release
$ curl -fLO https://github.com/u1and0/jtr/releases/download/v0.2.8/jtr-linux.zip
$ unzip jtr-linux.zip
$ chmod 755 ./jtr
$ ./jtr -v