5
23
Fork
You've already forked ijq
0
Interactive jq
  • Go 99.3%
  • Makefile 0.7%
Find a file
Gregory Anders 6b77e5f7fd
All checks were successful
ci/woodpecker/pull_request_closed/woodpecker Pipeline was successful
ci/woodpecker/pr/woodpecker Pipeline was successful
ci/woodpecker/push/woodpecker Pipeline was successful
Only run CI on "push" events for master branch
2026年04月24日 11:01:38 -05:00
demo Add demo GIF 2022年12月17日 20:30:52 -07:00
internal Organize imports 2026年03月03日 15:26:11 -06:00
testdata Add race condition tests 2026年03月03日 13:01:29 -06:00
.gitattributes Refactor options handling 2026年03月03日 11:49:33 -06:00
.gitignore Add initial tests 2021年04月17日 06:46:16 -04:00
.woodpecker.yaml Only run CI on "push" events for master branch 2026年04月24日 11:01:38 -05:00
config.go Organize imports 2026年03月03日 15:26:11 -06:00
config_test.go Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00
COPYING Switch to GPLv3 license 2020年11月06日 07:38:27 -07:00
flags_test.go Organize imports 2026年03月03日 15:26:11 -06:00
go.mod Add a menu 2026年03月03日 09:18:59 -06:00
go.sum Add support for a configuration file 2026年02月26日 16:17:26 -06:00
history.go Fix permissions on history file after rewrite 2026年03月03日 11:49:33 -06:00
history_test.go Fix permissions on history file after rewrite 2026年03月03日 11:49:33 -06:00
ijq.1.scd Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00
keymap.go Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00
keymap_test.go Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00
main.go Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00
main_test.go Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00
Makefile Version 1.3.0 2026年03月03日 14:49:33 -06:00
race_test.go Initial implementation of UI test 2026年03月06日 09:52:24 -06:00
README.md Add CI badge to README 2026年03月03日 14:44:21 -06:00
README.srht.html Set custom README for sourcehut 2024年12月16日 16:14:42 -06:00
ui_test.go Cleanup key bindings and update man page 2026年04月24日 10:53:15 -05:00

ijq

CI status

Interactive jq tool. Like jqplay for the commandline.

Demo

Demo

Installation

Install from package manager

Packaging status

Build from source

Install go. To install ijq under /usr/local/bin/ simply run

make install

from the root of the project. To install to another location, set the PREFIX variable, e.g.

make PREFIX=~/.local install

To generate the man page you will also need to have scdoc installed.

Usage

ijq uses jq under the hood, so make sure you have that installed first.

Read from a file:

ijq file.json

Read from stdin:

curl -s https://api.github.com/users/gpanders | ijq

Press Return to close ijq and print the current filtered output to stdout. This will also print the current filter to stderr. This allows you to save the filter for re-use with jq in the future:

ijq file.json 2>filter.jq
# Same output as above
jq -f filter.jq file.json

Pressing Return also saves the filter to a history file ($XDG_DATA_HOME/ijq/history by default). You can browse the history by deleting everything in the filter field. Change the history file used with the history-file setting in $XDG_CONFIG_HOME/ijq/config (or ~/.config/ijq/config when $XDG_CONFIG_HOME is unset). Set history-file to an empty string to disable history entirely.

If $XDG_DATA_HOME is undefined, ~/.local/share/ijq/history is used.

Press Ctrl+s to save the current filter to history without exiting. A confirmation popup is shown and can be dismissed with any key.

Use Shift plus the arrow keys to move between the different windows. When either of the input or output views have focus, you can use the arrow keys to scroll up and down. Vi keys also work, i.e. you can use j/k to scroll up or down, g to move to the top of the view, G to jump to the bottom of the view, and Ctrl-F/Ctrl-B to scroll up or down a page at a time.

Press Ctrl-/ to open an overlay menu (Ctrl-? and Ctrl-_ are also accepted) with some useful actions and configuration options.

Use Esc to go back to the root overlay menu (or close it from the root), and use q to close the overlay from any subview.

Use Ctrl-C to close the overlay when it is open, or to exit ijq immediately (discarding all filters and state) when the overlay is closed.

You can configure the colors by setting the JQ_COLORS environment variable. See the jq documentation for more details.

Contributing

Bugs can be reported on the issue tracker. PRs are accepted on GitHub or Codeberg.

Note for Packagers

Subscribe to release announcements on Codeberg to be notified of new releases, or subscribe to the RSS feed.

Similar Work

License

GPLv3