diff --git a/.github/workflows/issue-comment.yml b/.github/workflows/issue-comment.yml new file mode 100644 index 0000000000..70004a0b5f --- /dev/null +++ b/.github/workflows/issue-comment.yml @@ -0,0 +1,38 @@ +on: + issue_comment: + types: [created] + +name: Add issues workflow labels + +jobs: + add-label-if-is-author: + runs-on: ubuntu-latest + if: (github.event.issue.user.id == github.event.comment.user.id) && !github.event.issue.pull_request && (github.event.issue.state == 'open') + steps: + - name: Add require handle label + uses: actions-cool/issues-helper@v2 + with: + actions: 'add-labels' + labels: 'status: pending' + + - name: Remove require reply label + uses: actions-cool/issues-helper@v2 + with: + actions: 'remove-labels' + labels: 'status: waiting for feedback' + + add-label-if-not-author: + runs-on: ubuntu-latest + if: (github.event.issue.user.id != github.event.comment.user.id) && !github.event.issue.pull_request && (github.event.issue.state == 'open') + steps: + - name: Add require replay label + uses: actions-cool/issues-helper@v2 + with: + actions: 'add-labels' + labels: 'status: waiting for feedback' + + - name: Remove require handle label + uses: actions-cool/issues-helper@v2 + with: + actions: 'remove-labels' + labels: 'status: pending'