hoshsadiq
Joined 5 years ago
Joined 5 years ago
I considered forking jid/jiq and using gojq as a library, but I ended up not going down that route because of reasons that I cannot remember. I also considered using a tui or something but FZF has so much already implemented and has a lot of it right, and I didn't particularly feel like re-inventing the wheel.
It is essentially similar to jqplay but local.
I didn't use jid/jiq because jid uses go-simplejson, which is nowhere near as powerful as jq, and jiq seemed very buggy when I used it and it felt like it was hacked together. Plus there was no where to change jq's arguments while running it.
I'm sure this function can be improved on, but this has been good enough for me so far.
Also, I run gojq[2] instead of jq. It is a drop-in replacement for jq but is written in Go, and has some improvements over jq such as bug fixes, support for yaml input, and it also provides more helpful error messages.
[0] https://github.com/hoshsadiq/dot_files/blob/master/zshrc.d/m...
They used to provide relatively recent builds in their kubic repos. Unfortunately, for some reason, they decided to discontinue it[0]. They mentioned some CVEs or something in some issues raised around this, but to me that means pushing a new version/build and not discontinuing it.
Anyway, one of the members of the Containers org provides unstable kubic repos[1][2] for non RH systems. Unfortunately, this includes RCs, and non-stable versions, which is fine to get bleeding edge, but I'd rather just have the stable versions.
Due to the above, I've written some scripts to build deb packages for all the latest stable versions. So hopefully you can simply download the deb from GH releases[3] and then `dpkg -i *.deb && apt-get install -f`.
[0] https://podman.io/blogs/2022/04/05/ubuntu-2204-lts-kubic.htm...
[1] https://github.com/containers/podman/issues/14302#issuecomme...
[2] https://build.opensuse.org/project/show/devel:kubic:libconta...
[3] https://github.com/hoshsadiq/podman-deb/releases