npx skills add ...
npx skills add github/gh-aw --skill github-discussion-query
npx skills add github/gh-aw --skill github-discussion-query
Query GitHub discussions with jq filtering and reusable selectors.
Query GitHub discussions efficiently with built-in jq filtering.
The --jq parameter is optional. Without --jq, this skill returns schema and data size information instead of full data.
Use this to avoid oversized responses and inspect structure before targeted queries.
Use --jq '.' to get all data, or use a more specific filter for targeted results.
Use this skill to query discussions from the current repository or any specified repository.
To list discussions from the current repository:
To get all discussion data:
To query a specific repository:
Use the --jq argument to filter and transform the output:
--limit: Maximum number of discussions to fetch. Default: 30--repo: Repository in owner/repo format. Default: current repo--jq: (Optional) jq expression for filtering/transforming output. If omitted, returns schema infoFind discussions with many comments:
Get unanswered discussions:
List discussions with their labels:
Find discussions by category:
Get recently updated discussions:
The script outputs JSON by default, making it easy to pipe through jq for additional processing.
gh) authenticatedjq for filtering (installed by default on most systems)./query-discussions.sh --jq '.[] | select(.comments.totalCount > 5) | {number, title, comments: .comments.totalCount}'./query-discussions.sh --jq '.[] | select(.answer == null) | {number, title, category: .category.name}'./query-discussions.sh --jq '.[] | {number, title, labels: [.labels[].name]}'./query-discussions.sh --jq '.[] | select(.category.name == "Q&A") | {number, title, author: .author.login}'./query-discussions.sh --jq 'sort_by(.updatedAt) | reverse | .[0:10] | .[] | {number, title, updatedAt}'