Skip to content

Commit

Permalink
Add try support via GitHub action
Browse files Browse the repository at this point in the history
  • Loading branch information
mrobinson committed Jul 19, 2023
1 parent ae3f33b commit e35edc5
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/run-workflow-on-comment.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
on: issue_comment

jobs:
pr_commented:
# This job only runs for pull request comments
name: PR comment
if: ${{ github.event.issue.pull_request }}
runs-on: ubuntu-latest
steps:
- run: |
echo The comment "${{ github.event.comment }}"
echo Made by "${{ github.event.sender }}"
- uses: actions/github-script@v6
id: permissions
with:
result-encoding: string
script: |
return github.rest.repos.getCollaboratorPermissionLevel({
owner: context.repo.owner,
repo: context.repo.repo,
username: context.event.sender,
});
- run: |
echo Permissions level "${{ steps.permissions.outputs.result }}"

0 comments on commit e35edc5

Please sign in to comment.