rwxrob-dot/snippets/bash/jsonstr
Rob Muhlestein 2ea0289e9f Rebase
2022-02-09 02:29:05 -05:00

13 lines
145 B
Plaintext

_buffer() {
[[ -n "$1" ]] && return 1
"${FUNCNAME[1]}" "$(</dev/stdin)"
}
_jsonstr() {
_buffer "$@" && return $?
jq -MRsc <<< "$1"
}