Skip to content

Conversation

@Mrunalisa
Copy link
Contributor

This PR updates the workflow file .github/workflows/pr-preview.yml to fix the 403 permission denied error when deploying previews with GitHub Actions.

Changes Made

Added permissions: contents: write to the workflow job so that github-actions[bot] can push to the preview branch.

Ensured the deployment step uses the built-in GITHUB_TOKEN with the correct permissions.

Why this change?

The deploy step was failing with the following error:

remote: Permission to .git denied to github-actions[bot].
fatal: unable to access 'https://github.com/...': The requested URL returned error: 403

This happened because the workflow did not have write access to repository contents.

Impact

Fixes deployment of PR preview to GitHub Pages.

Ensures contributors can see live previews for pull requests.

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Your free trial has ended. If you'd like to continue receiving code reviews, you can add a payment method here.

@adityai0 adityai0 merged commit 3d5d7ff into opensource-society:main Aug 17, 2025
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants