-
Notifications
You must be signed in to change notification settings - Fork 116
33 lines (32 loc) · 1.14 KB
/
add-to-inbox.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: Add to Inbox 📥
on:
issues:
types: [opened, reopened]
jobs:
add-to-inbox:
if: ${{ github.repository == 'primer/view_components' }}
runs-on: ubuntu-latest
env:
ISSUE_URL: ${{ github.event.issue.html_url }}
PROJECT_ID: 4503
steps:
- id: get-primer-access-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.PRIMER_ISSUE_TRIAGE_APP_ID }}
private-key: ${{ secrets.PRIMER_ISSUE_TRIAGE_APP_PRIVATE_KEY }}
- name: Add rails label to issue
run: |
gh issue edit $ISSUE_URL --add-label rails
env:
GH_TOKEN: ${{ steps.get-primer-access-token.outputs.token }}
- id: get-github-access-token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.PRIMER_ISSUE_TRIAGE_APP_ID_FOR_GITHUB }}
private-key: ${{ secrets.PRIMER_ISSUE_TRIAGE_APP_PRIVATE_KEY_FOR_GITHUB }}
owner: github
- name: Add issue to project
run: gh project item-add $PROJECT_ID --url $ISSUE_URL --owner github
env:
GH_TOKEN: ${{ steps.get-github-access-token.outputs.token }}