What is a Pull Request?
A pull request (PR) is a way to propose changes from one branch (or fork) into another. It enables team members to review code, discuss changes, and ensure quality before merging.
Creating a Pull Request
- Push your feature branch to MokoGitea.
- Navigate to the repository and click Pull Requests → New Pull Request.
- Select the source branch (your feature branch) and the target branch (e.g.,
main). - Write a clear Title and Description explaining what you changed and why.
- Assign Reviewers, Labels, and a Milestone as needed.
- Click New Pull Request.
Reviewing a Pull Request
Reviewers can examine the changes and provide feedback:
- Files Changed tab — See a diff of all modifications.
- Inline Comments — Click any line to leave a comment directly on that code.
- Review Submission — Submit your review as Approve, Request Changes, or Comment.
Merge Options
When a PR is approved and ready, you can merge it using one of three strategies:
- Merge Commit — Creates a merge commit preserving full branch history.
- Rebase — Replays your commits on top of the target branch for a linear history.
- Squash — Combines all commits into a single commit for a clean log.
Your repository administrator may restrict which merge methods are available.
Resolving Merge Conflicts
If your branch has conflicts with the target branch, MokoGitea will notify you. You can resolve conflicts:
- In the web editor — For simple conflicts, use the built-in conflict resolver.
- Locally — Pull the target branch, resolve conflicts in your editor, commit, and push.
Branch Protection and Required Reviews
Administrators can require one or more approving reviews before a PR can be merged. This is configured under Settings → Branches → Branch Protection. Protected branches can also require passing CI/CD checks before merge.