Update 4_2__Interlude_Using_JQ.md

This commit is contained in:
Shannon Appelcline 2017-03-29 16:04:08 -07:00 committed by GitHub
parent 911081a092
commit 72eb94b0bb

View File

@ -29,7 +29,7 @@ $ bitcoin-cli signrawtransaction $rawtxhex
``` ```
Fortunately, JQ can easily capture data of that sort! Fortunately, JQ can easily capture data of that sort!
To use JQ, run `jq` at the backend of a pipe, and always use the standard invocation of `jq -r '.'`. The `-r` tells JQ to produce raw output, which will work for command-line variables, while the `.` tells jq to ouput. We protected it in `' '` because we'll need that protection later. To use JQ, run `jq` at the backend of a pipe, and always use the standard invocation of `jq -r '.'`. The `-r` tells JQ to produce raw output, which will work for command-line variables, while the `.` tells jq to ouput. We protect those argument in `' '` because we'll need that protection later as our `jq` invocations get more complex.
To capture a specific value from a JSON object, you just list the key after the `.`: To capture a specific value from a JSON object, you just list the key after the `.`:
``` ```