Skip to content

Commit 5da1540

Browse files
authored
feat: capture additional RCA fields ( repository + issue url ) (#103)
* new-fields * form refactor
1 parent 617b798 commit 5da1540

File tree

1 file changed

+19
-4
lines changed

1 file changed

+19
-4
lines changed

.github/workflows/post-gh-rca.yml

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
inputs:
1010
google-form-base-url:
1111
description: Base URL of the Google Form.
12-
required: true
12+
default: 'https://docs.google.com/forms/d/e/1FAIpQLSeLOVVUy7mO1j-5Isb04OAWk3dM0b1NY1R8kf0tiEBs9elcEg/viewform?usp=pp_url'
1313
type: string
1414
repo-owner:
1515
description: The repo owner
@@ -29,15 +29,23 @@ on:
2929
type: string
3030
entry-issue:
3131
description: The entry ID for the issue field in the Google Form
32-
required: true
32+
default: 'entry.1417567074'
3333
type: string
3434
entry-regression:
3535
description: The entry ID for the regression field in the Google Form
36-
required: true
36+
default: 'entry.1470697156'
3737
type: string
3838
entry-team:
3939
description: The entry ID for the team field in the Google Form
40-
required: true
40+
default: 'entry.1198657478'
41+
type: string
42+
entry-repo-name:
43+
description: The entry ID for the repository name field
44+
default: 'entry.1085838323'
45+
type: string
46+
entry-issue-url:
47+
description: The entry ID for the GitHub issue URL field
48+
default: 'entry.516762472'
4149
type: string
4250

4351
jobs:
@@ -56,6 +64,8 @@ jobs:
5664
ENTRY_ISSUE: ${{ inputs.entry-issue }}
5765
ENTRY_REGRESSION: ${{ inputs.entry-regression }}
5866
ENTRY_TEAM: ${{ inputs.entry-team }}
67+
ENTRY_REPO_NAME: ${{ inputs.entry-repo-name }}
68+
ENTRY_ISSUE_URL: ${{ inputs.entry-issue-url }}
5969
with:
6070
github-token: ${{ secrets.GITHUB_TOKEN }}
6171
script: |
@@ -64,6 +74,8 @@ jobs:
6474
ENTRY_ISSUE,
6575
ENTRY_REGRESSION,
6676
ENTRY_TEAM,
77+
ENTRY_REPO_NAME,
78+
ENTRY_ISSUE_URL,
6779
OWNER_NAME: owner,
6880
REPO_NAME: repo,
6981
ISSUE_NUMBER: issueNumStr,
@@ -109,6 +121,9 @@ jobs:
109121
teamLabels.length ? teamLabels.join(',') : ''
110122
);
111123
124+
formUrl.searchParams.set(ENTRY_REPO_NAME, repo);
125+
formUrl.searchParams.set(ENTRY_ISSUE_URL, `https://github.com/${owner}/${repo}/issues/${issue_number}`);
126+
112127
const assignees = issue.assignees.map(u=>`@${u.login}`).join(', ');
113128
const body = `Hi ${assignees},
114129

0 commit comments

Comments
 (0)