1
0
mirror of https://github.com/arduino/library-registry.git synced 2025-07-04 10:22:30 +03:00

Provide immediate response to comment trigger

When there is a problem with the submission that must be resolved in the library repository, a comment mentioning
`@ArduinoBot` is used to trigger the "Manage PRs" workflow.

We are accustomed to seeing the checks status in the PR thread when workflows are running. However, with a comment
triggered workflow this does not happen. The only indication of the workflow running is on the "Actions" tab. This can
leave the submitter wondering if their comment had any effect as the workflow takes some time to run before providing
feedback.

This uncertainty can be avoided by making the bot immediately comment to acknowledge that the check is in progress.
This commit is contained in:
per1234
2021-04-25 23:07:25 -07:00
parent 7ebdf19341
commit 83b4acfac7

View File

@ -31,8 +31,23 @@ jobs:
) )
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Dummy step to make job valid - name: Comment on comment trigger to provide feedback
run: "" if: github.event_name == 'issue_comment'
uses: octokit/request-action@v2.x
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
route: POST /repos/{owner}/{repo}/issues/{issue_number}/comments
owner: ${{ github.repository_owner }}
repo: ${{ github.event.repository.name }}
issue_number: ${{ github.event.pull_request.number }}${{ github.event.issue.number }}
body: |
|
Hello! I'm checking your submission again.
You can see the progress here:
https://github.com/${{ github.repository_owner }}/${{ github.event.repository.name }}/actions/workflows/manage-prs.yml
diff: diff:
needs: needs:
- enabled - enabled