Maintaining

Checking and modifying a Codeberg pull request

To modify a PR with "Allow edits from maintainers" enabled, you can directly edit the merging branch of the forked repo. You can do so via Codeberg's web UI, or more preferably, by using the commands below on your local repo:

  1. Add a local remote named "contributor" that points to the contributor's forked repo: git remote add contributor https://codeberg.org/<contributor-username>/Arcticons-Selfhosted.git

  2. Fetch the merging branch of that contributor's repo (usually main). This retrieves their updates into internal Git data and does not change your files yet: git fetch contributor main

  3. Create a local branch (e.g. contributor-main-pr) that tracks the contributor branch we fetched in previous step: git checkout -b contributor-main-pr contributor/main You will be switched to the newly-created branch that has the contributor's changes as it is shown on the PR.

  4. Now you can edit the files, and commit them once you're done git add . && git commit -m "improvements"

  5. To push these commits back to the contributor's remote repository: git push contributor HEAD:main

  6. Lastly, you can switch back to the main branch and delete contributor info to cleanup your project directory: git switch main git branch -D contributor-main-pr git remote remove contributor

Last updated

Was this helpful?