EMZETT.
Login

Pull request

In short: A pull request (PR, “merge request” on GitLab) is the request to take changes from one branch into another, usually the main branch.

In more detail: On Git platforms such as GitHub and GitLab you work on your own branch. When the work is done you open a pull request. The team sees the changes, comments and approves them.

In Depth

  • Flow: create branch → commit changes → push branch → open pull request → review and automated tests → merge.
  • Benefit: four-eyes principle, better quality, documentation of changes, automatic checks (CI).
  • Merge conflicts: arise when two people change the same spot. They are easy to avoid by merging the main branch in often and making small, clear pull requests (merge conflicts).
  • Good PRs: small changes, meaningful title and description, tests, no secrets in code.

See also: Git, merge conflicts