now shows post URLs instead of null->null if available
This commit is contained in:
@@ -12,7 +12,7 @@ TOKE=${tokes[0]}
|
||||
baseurl="https://$INSTANCE/api/v3/"
|
||||
# Please don't abuse jq like this
|
||||
showcomment='(.post | (.id | tostring)+" "+(.name | tostring)),
|
||||
(.comment | (.parent_id | tostring)+"->"+(.id | tostring))+", "+(.creator.display_name // .creator.name)+":",
|
||||
(.post.url // (.comment | (.parent_id | tostring)+"->"+(.id | tostring)))+", "+(.creator.display_name // .creator.name)+":",
|
||||
((.comment // .post) | .published,
|
||||
(.body // .content)),
|
||||
""'
|
||||
@@ -47,4 +47,4 @@ while getopts "a:h" o;do case "${o}" in
|
||||
esac done
|
||||
shift $((OPTIND-1))
|
||||
|
||||
$*
|
||||
$*
|
||||
|
Reference in New Issue
Block a user