-
Notifications
You must be signed in to change notification settings - Fork 1.8k
40 lines (35 loc) · 1.24 KB
/
contribution-ready-to-be-worked.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
name: Contribution triage - ready to be worked
on:
issues:
types: [unlabeled]
permissions:
issues: write
jobs:
add-comment:
name: Add comment to issues with proposal accepted and community contribution
runs-on: ubuntu-latest
steps:
- name: Log github event
env:
$GITHUB_CONTEXT_LABELS: ${{ toJson(github.event.label) }}
run: echo "$GITHUB_CONTEXT_LABELS"
- name: Conditional Check and Add Comment
id: conditional-comment
uses: actions/github-script@d7906e4ad0b1822421a7e6a35d5ca353c962f410 #v6.4.1
with:
script: |
response = await github.rest.issues.listLabelsOnIssue({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
});
comments = await github.rest.issues.listComments({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
});
console.log('here', github.event)
console.log('there', github)
- name: Set Output
if: steps.conditional-comment.outcome == 'success'
run: echo "Comment added successfully."