Add a label to an issue.
gh label 60 bug
Returns all issues that:
- are open
- have zero labels or lack at least one of
p1
,p2
,p3
,needs-design
,blocked
,needs-user-input
,core
, orhelp-wanted
aliases: | |
label: '!jq -n "{\"labels\":[\"$2\"]}" | ghd api "repos/:owner/:repo/issues/$1/labels" --input -' | |
triage: '!ghd api graphql --paginate -Fquery=''query($endCursor:String){repository(owner:"cli",name:"cli"){issues(first:100,states:OPEN,after:$endCursor){pageInfo{hasNextPage endCursor}edges{node{number title labels(first:10){totalCount edges{node{name}}}}}}}}'' | jq -r ''.data.repository.issues.edges|map(.node)|map(select(any(.labels.edges[]; .node.name | test("p1|p2|p3|core|help wanted|tracking issue|needs-design|blocked|needs-user-input")) | not))|map("\(.number)\t\(.title)")|.[]''' |
@