tidwall/jj là dự án mã nguồn mở trên GitHub, viết chủ yếu bằng Go, với 2.1k sao. JSON Stream Editor (command line utility)
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
JJ is a command line utility that provides a fast and simple way to retrieve or update values from JSON documents.
It's powered by GJSON and SJSON under the hood.
It's fast because it avoids parsing irrelevant sections of json, skipping over values that do not apply, and aborts as soon as the target value has been found or updated.
Getting started
Install
Mac (Homebrew)
brew install tidwall/jj/jj
Build
make
Or download a pre-built binary for Linux, OSX, Windows, or FreeBSD.
Usage
$ jj -h
usage: jj [-v value] [-purOD] [-i infile] [-o outfile] keypath
examples: jj keypath read value from stdin
or: jj -i infile keypath read value from infile
or: jj -v value keypath edit value
or: jj -v value -o outfile keypath edit value and write to outfile
options:
-v value Edit JSON key path value
-p Make json pretty, keypath is optional
-u Make json ugly, keypath is optional
-r Use raw values, otherwise types are auto-detected
-n Do not output color or extra formatting
-O Performance boost for value updates
-D Delete the value at the specified key path
-l Output array values on multiple lines
-i infile Use input file instead of stdin
-o outfile Use output file instead of stdout
keypath JSON key path (like "name.last")
Examples
Getting a value
JJ uses a path syntax for finding values.
Get a string:
$ echo '{"name":{"first":"Tom","last":"Smith"}}' | jj name.last
Smith
Get a block of JSON:
$ echo '{"name":{"first":"Tom","last":"Smith"}}' | jj name
{"first":"Tom","last":"Smith"}
The path syntax for setting values has a couple of tiny differences than for getting values.
The -v value option is auto-detected as a Number, Boolean, Null, or String.
You can override the auto-detection and input raw JSON by including the -r option.
This is useful for raw JSON blocks such as object, arrays, or premarshalled strings.
Update a value:
$ echo '{"name":{"first":"Tom","last":"Smith"}}' | jj -v Andy name.first
{"name":{"first":"Andy","last":"Smith"}}
Set a new value:
$ echo '{"name":{"first":"Tom","last":"Smith"}}' | jj -v 46 age
{"age":46,"name":{"first":"Tom","last":"Smith"}}
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/tidwall/jj là nguồn chính thức.
tidwall/jj có bao nhiêu sao?
tidwall/jj có 2.1k sao GitHub — tải lại trang để xem số mới nhất, hoặc xem trực tiếp github.com/tidwall/jj. TopGit phản chiếu số sao của GitHub nhưng không cam kết đến từng phút.
tidwall/jj có phải mã nguồn mở không?
Có — tidwall/jj phát hành theo license MIT, nghĩa là mã nguồn mở để đọc, fork và (tùy license) tái sử dụng. Mã: github.com/tidwall/jj.
tidwall/jj có website riêng không?
TopGit chưa ghi nhận URL trang chủ cho tidwall/jj. Phần README ở tab phía trên thường có link demo, hoặc xem mô tả GitHub của repo.
tidwall/jj là gì?
tidwall/jj (tidwall/jj) là dự án Go trên GitHub. Theo mô tả gốc: JSON Stream Editor (command line utility)
Đọc đầy đủ README ở tab phía trên.
Chưa chắc jj có hợp với bạn?
Để ChatGPT, Claude hoặc Perplexity tìm hiểu giúp — bấm bên dưới và xem AI nói gì về jj.