-
Notifications
You must be signed in to change notification settings - Fork 3
51 lines (46 loc) · 1.69 KB
/
move_issues.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Move Issues
# DynamoWishlist project https://github.com/orgs/DynamoDS/projects/3
# Built-in workflow https://github.com/orgs/DynamoDS/projects/3/workflows
# The built-in workflow
# - adds any new issues to the project
# - sets status as 'Triage' when an item is added to the project
# - sets status as 'Backlog' when an item is reopened
# - sets status as 'Done' when an item is closed
# This workflow complements the built in workflow and
# - moves any labeled issues to 'Backlog' column in the project
# - moves issues labeled as 'tracked' to 'Todo' column in the project
on:
issues:
types:
- labeled
env:
gh_token: ${{ secrets.DYNAMO_ISSUES_TOKEN }}
gh_organization: ${{ github.repository_owner }}
project_id: 3
jobs:
issue_labeled_any:
name: Move any labeled issue
runs-on: ubuntu-latest
if: github.event.label.name != 'Tracked'
steps:
- name: Move issue to Backlog
uses: leonsteinhaeuser/[email protected]
with:
gh_token: ${{ env.gh_token }}
organization: ${{ env.gh_organization }}
project_id: ${{ env.project_id }}
resource_node_id: ${{ github.event.issue.node_id }}
status_value: Backlog
issue_labeled_as_tracked:
name: Move issue labeled as 'Tracked'
runs-on: ubuntu-latest
steps:
- name: Move issue to Todo
if: github.event.label.name == 'Tracked'
uses: leonsteinhaeuser/[email protected]
with:
gh_token: ${{ env.gh_token }}
organization: ${{ env.gh_organization }}
project_id: ${{ env.project_id }}
resource_node_id: ${{ github.event.issue.node_id }}
status_value: Todo