Skip to content

Commit ea40465

Browse files
Merge pull request #4 from microsoft/copilot/fix-3abd4a9a-bcf3-48e4-85fc-b3efd4aa1117
Add GitHub workflow for automatic issue management
2 parents def77fd + 9e11dd3 commit ea40465

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Add new issues to Ignite GH Project
2+
3+
on:
4+
issues:
5+
types:
6+
- opened
7+
8+
jobs:
9+
add-to-project:
10+
name: Add issue to project
11+
runs-on: ubuntu-latest
12+
permissions: {}
13+
steps:
14+
- uses: actions/add-to-project@v1.0.2
15+
with:
16+
project-url: ${{ secrets.GH_PROJECT_URL }}
17+
github-token: ${{ secrets.ADD_TO_PROJECT }}
18+
label_issues:
19+
needs: add-to-project
20+
runs-on: ubuntu-latest
21+
permissions:
22+
issues: write
23+
steps:
24+
- run: |
25+
if [ -n "$LABELS" ]; then
26+
gh issue edit "$NUMBER" --add-label "$LABELS"
27+
else
28+
echo "No label to add."
29+
fi
30+
env:
31+
GH_TOKEN: ${{ secrets.ADD_TO_PROJECT }}
32+
GH_REPO: ${{ github.repository }}
33+
NUMBER: ${{ github.event.issue.number }}
34+
LABELS: ${{ secrets.ISSUE_LABEL }}

0 commit comments

Comments
 (0)