* Function eXecution
Command-line JSON processing tool
- Easy to use
- Standalone binary
- Interactive mode ๐
- Themes support ๐จ
- Streaming support ๐
$ npm install -g fx
Or via Homebrew
$ brew install fx
Or download standalone binary from releases page.
Did you like fx? Buy me a beer ๐บ or โฟ
Start interactive mode without passing any arguments.
$ curl ... | fx
Or by passing filename as first argument.
$ fx data.json
Pipe into fx
any JSON and anonymous function for reducing it.
$ curl ... | fx 'json => json.message'
Or same as above but short.
$ curl ... | fx this.message
$ curl ... | fx .message
Pass any numbers of arguments as code.
$ curl ... | fx 'json => json.message' 'json => json.filter(x => x.startsWith("a"))'
Access all lodash (or ramda, etc) methods by using .fxrc file.
$ curl ... | fx '_.groupBy("commit.committer.name")' '_.mapValues(_.size)'
Update JSON using spread operator.
$ echo '{"count": 0}' | fx '{...this, count: 1}'
{
"count": 1
}
Pretty print JSON with dot.
$ curl ... | fx .
And try this:
$ fx --life
See full documentation.
- xx โ fx-like JSON tool (go)
- eat โ converts anything into JSON
- ymlx โ fx-like YAML cli processor
- fx-theme-monokai โ monokai theme
- fx-theme-night โ night theme