Skip to content

docs(example): set permissions and only post on pr #75

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 29, 2024

Conversation

StaticRocket
Copy link
Contributor

Update the example so it only attempts to post comments on the PR action and set the permissions fields to the minimum values required to leave comments on PRs.

Update the example so it only attempts to post comments on the PR action
and set the permissions fields to the minimum values required to leave
comments on PRs.

Signed-off-by: Randolph Sapp <rs@ti.com>
@shenxianpeng shenxianpeng changed the title doc(example): set permissions and only post on pr docs(example): set permissions and only post on pr Oct 29, 2024
@shenxianpeng
Copy link
Contributor

Thank you for your PR! I really like the changes, especially the pr-comments: ${{ github.event_name == 'pull_request' }}.

However, I'm still seeing an error in the logs when posting comments. This might be because you’re working from a forked repo (posting comments worked successfully for an unforked PR in #76).

Error posting PR comment: 403 {"message": "Resource not accessible by integration", "documentation_url": "https://docs.github.com/rest/issues/comments#create-an-issue-comment", "status": "403"}

@shenxianpeng
Copy link
Contributor

shenxianpeng commented Oct 29, 2024

Maybe it should have pull_request_target in https://github.com/commit-check/commit-check-action/blob/main/.github/workflows/commit-check.yml#L4 for fork repo

I created #77 for tracking the above issue.

@shenxianpeng shenxianpeng merged commit 1ccc4e4 into commit-check:main Oct 29, 2024
0 of 2 checks passed
@shenxianpeng shenxianpeng added the documentation Improvements or additions to documentation label Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants