-
Notifications
You must be signed in to change notification settings - Fork 1
52 lines (46 loc) · 1.37 KB
/
add-to-project.yaml
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
52
name: add to project
on:
workflow_call:
inputs:
classic:
required: true
type: boolean
org:
required: true
type: string
project-number:
required: true
type: string
secrets:
SENZING_GITHUB_ACCESS_TOKEN:
required: false
SENZING_GITHUB_PROJECT_RW_TOKEN:
required: false
permissions:
repository-projects: write
jobs:
# Does not support classic projects
add-to-project:
name: add to project
runs-on: ubuntu-latest
steps:
- name: add to project
if: ${{ ! inputs.classic }}
uses: actions/add-to-project@v1.0.2
with:
github-token: ${{ secrets.SENZING_GITHUB_PROJECT_RW_TOKEN }}
project-url: "https://github.com/orgs/${{inputs.org}}/projects/${{inputs.project-number}}"
# https://github.com/srggrs/assign-one-project-github-action/issues/89
# Only classic projects supported
add-to-classic-project:
name: add to classic project
runs-on: ubuntu-latest
steps:
- name: add to classic project
env:
GITHUB_TOKEN: ${{ secrets.SENZING_GITHUB_ACCESS_TOKEN }}
if: ${{ inputs.classic }}
uses: senzing-factory/github-action-add-issue-to-project@v1
with:
column_name: "Backlog"
project: "https://github.com/orgs/${{inputs.org}}/projects/${{inputs.project-number}}"