Skip to content

Commit f36c2bd

Browse files
Use graphql api to determine linked issues (#14)
* Compile * Use Graphql to get linkedissues * Remove mention of limitation from README --------- Co-authored-by: Ronald van Rij <ronald.rij@logius.nl> Co-authored-by: Ronald van Rij <ronaldvanrij@users.noreply.github.com>
1 parent 73648fe commit f36c2bd

7 files changed

Lines changed: 2986 additions & 1033 deletions

File tree

README.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# copy-issue-labels github action
22

3-
Motivation for creating this action was to copy labels from linked issues to the issue / PR which triggered workflow.
3+
Motivation for creating this action was to copy labels from linked issues to the issue / PR which triggered the workflow.
44

55
## Example workflow
66

7-
This workflow will copy labels from the linked issue for the opened PR.
7+
This workflow will copy labels from any linked issue for the opened PR.
88

99
Github issues can link other issues and this linking is done automatically whenever PR mentions one of the keywords for automated workflows. [See documentation](https://docs.github.com/en/free-pro-team@latest/github/managing-your-work-on-github/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword)
1010

@@ -35,8 +35,6 @@ There is also support for different workflows to trigger sync of the labels with
3535
issue-number: ${{ github.event.inputs.issue }}
3636
```
3737

38-
Because GitHub API doesn't provide information about linked issues this workflow will parse the information from the `body` of the issue.
39-
4038
## Custom keywords
4139

4240
You can provide custom keywords which will be picked up by the parser.

action.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ inputs:
1111
from-title:
1212
description: 'To parse the issue numbers from title, a boolean'
1313
required: false
14+
issue-number:
15+
description: 'Get linked issues from Pull Request number'
16+
required: false
1417
runs:
15-
using: 'node12'
18+
using: 'node16'
1619
main: 'dist/index.js'

0 commit comments

Comments
 (0)