Jq: Can't use both the --raw-output and --ascii-output switches

Created on 26 Jan 2018  路  2Comments  路  Source: stedolan/jq

If both the --raw-output and the --ascii-output command line switches are used, the --ascii-output switch is ignored:

$ echo "{\"key1\":\"\\ud83d\\ude00\"}" | jq --raw-output '.key1'
馃榾
$ echo "{\"key1\":\"\\ud83d\\ude00\"}" | jq --ascii-output '.key1'
"\ud83d\ude00"
$ echo "{\"key1\":\"\\ud83d\\ude00\"}" | jq --raw-output --ascii-output '.key1'
馃榾

What I'd expect is that in the last example the output would be:

$ echo "{\"key1\":\"\\ud83d\\ude00\"}" | jq --raw-output --ascii-output '.key1'
\ud83d\ude00
bug

All 2 comments

Closed with bf88c73c20ff1642aa2566ae67df18ca5b4b63ab via #1587 by @rain-1. Thanks!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sonots picture sonots  路  3Comments

rclod picture rclod  路  4Comments

ghost picture ghost  路  4Comments

thedward picture thedward  路  3Comments

kelchy picture kelchy  路  4Comments