Skip to content

Instantly share code, notes, and snippets.

@nestoralonso
Last active August 27, 2021 18:22
Show Gist options
  • Save nestoralonso/396ceecb2327b1f899e40f81decc2fc6 to your computer and use it in GitHub Desktop.
Save nestoralonso/396ceecb2327b1f899e40f81decc2fc6 to your computer and use it in GitHub Desktop.
JQ Example
curl https://api.github.com/repos/mrdoob/three.js/issues?per_page=100 | \
jq 'map({ title: .title, number: .number, labels: .labels | length }) | \
map(select(.labels > 0))'
# array constructor
jq '[ .[] | { title: .title, number: .number, labels: .labels | length } ]'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment