forked from jenkins-infra/helpdesk
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: auto label issues based on service(s) selected
Close jenkins-infra#12
- Loading branch information
1 parent
516486f
commit 7b08a53
Showing
1 changed file
with
18 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
name: Autolabeler | ||
on: | ||
issues: | ||
types: [opened, edited] | ||
jobs: | ||
autolabeler: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: stefanbuck/github-issue-praser@v2 | ||
id: issue-parser | ||
with: | ||
template-path: .github/ISSUE_TEMPLATE/1-report-issue.yml | ||
- run: echo "ISSUE_LABELS=$(echo '${{ steps.issue-parser.outputs.jsonString }}' | jq '.services' | tr '[:upper:]' '[:lower:]' | sed 's/"//g' | sed 's/ //g')" >> $GITHUB_ENV | ||
- uses: andymckay/labeler@master | ||
with: | ||
add-labels: ${{ env.ISSUE_LABELS }} | ||
remove-labels: "other" |