Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2023-02-20 16:49:51 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2023-02-20 16:49:51 +0300
commit71786ddc8e28fbd3cb3fcc4b3ff15e5962a1c82e (patch)
tree6a2d93ef3fb2d353bb7739e4b57e6541f51cdd71 /doc/user/project/merge_requests
parenta7253423e3403b8c08f8a161e5937e1488f5f407 (diff)
Add latest changes from gitlab-org/gitlab@15-9-stable-eev15.9.0-rc42
Diffstat (limited to 'doc/user/project/merge_requests')
-rw-r--r--doc/user/project/merge_requests/allow_collaboration.md4
-rw-r--r--doc/user/project/merge_requests/approvals/index.md2
-rw-r--r--doc/user/project/merge_requests/approvals/rules.md9
-rw-r--r--doc/user/project/merge_requests/approvals/settings.md17
-rw-r--r--doc/user/project/merge_requests/changes.md2
-rw-r--r--doc/user/project/merge_requests/cherry_pick_changes.md8
-rw-r--r--doc/user/project/merge_requests/commit_templates.md2
-rw-r--r--doc/user/project/merge_requests/conflicts.md6
-rw-r--r--doc/user/project/merge_requests/creating_merge_requests.md19
-rw-r--r--doc/user/project/merge_requests/csv_export.md2
-rw-r--r--doc/user/project/merge_requests/drafts.md9
-rw-r--r--doc/user/project/merge_requests/getting_started.md150
-rw-r--r--doc/user/project/merge_requests/index.md26
-rw-r--r--doc/user/project/merge_requests/methods/index.md2
-rw-r--r--doc/user/project/merge_requests/revert_changes.md2
-rw-r--r--doc/user/project/merge_requests/reviews/data_usage.md10
-rw-r--r--doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v13_8.pngbin42245 -> 0 bytes
-rw-r--r--doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v15_9.pngbin0 -> 14640 bytes
-rw-r--r--doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v13_8.pngbin38840 -> 0 bytes
-rw-r--r--doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v15_9.pngbin0 -> 10917 bytes
-rw-r--r--doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_4.pngbin20617 -> 0 bytes
-rw-r--r--doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_9.pngbin0 -> 9184 bytes
-rw-r--r--doc/user/project/merge_requests/reviews/index.md34
-rw-r--r--doc/user/project/merge_requests/status_checks.md22
24 files changed, 109 insertions, 217 deletions
diff --git a/doc/user/project/merge_requests/allow_collaboration.md b/doc/user/project/merge_requests/allow_collaboration.md
index d3d95a5bf61..0729e024df4 100644
--- a/doc/user/project/merge_requests/allow_collaboration.md
+++ b/doc/user/project/merge_requests/allow_collaboration.md
@@ -6,7 +6,7 @@ info: To determine the technical writer assigned to the Stage/Group associated w
# Collaborate on merge requests across forks **(FREE)**
-When you open a merge request from your fork, you can allow upstream
+When you open a merge request from your [fork](../repository/forking_workflow.md), you can allow upstream
members to collaborate with you on your branch.
When you enable this option, members who have permission to merge to the target branch get
permission to write to the merge request's source branch.
@@ -15,7 +15,7 @@ The members of the upstream project can then make small fixes or rebase branches
before merging.
This feature is available for merge requests across forked projects that are
-publicly accessible.
+[publicly accessible](../../public_access.md).
## Allow commits from upstream members
diff --git a/doc/user/project/merge_requests/approvals/index.md b/doc/user/project/merge_requests/approvals/index.md
index 92ff78082e3..21e2055cb61 100644
--- a/doc/user/project/merge_requests/approvals/index.md
+++ b/doc/user/project/merge_requests/approvals/index.md
@@ -8,8 +8,6 @@ disqus_identifier: 'https://docs.gitlab.com/ee/user/project/merge_requests/appro
# Merge request approvals **(FREE)**
-> Redesign [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/1979) in GitLab 11.8 and [feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/10685) in 12.0.
-
You can configure your merge requests so that they must be approved before
they can be merged. While [GitLab Free](https://about.gitlab.com/pricing/) allows
all users with Developer or greater [permissions](../../../permissions.md) to
diff --git a/doc/user/project/merge_requests/approvals/rules.md b/doc/user/project/merge_requests/approvals/rules.md
index 51f7254bfda..0a5e7c29860 100644
--- a/doc/user/project/merge_requests/approvals/rules.md
+++ b/doc/user/project/merge_requests/approvals/rules.md
@@ -254,6 +254,15 @@ the API.
For more information about this validation error, read
[issue 285129](https://gitlab.com/gitlab-org/gitlab/-/issues/285129).
+### Groups need explicit or inherited Developer role on a project
+
+A group created to handle approvals may be created in a different area of the
+project hierarchy than the project requiring review. If this happens, the approvals group
+isn't recognized as a valid Code Owner for the project, nor does it display in the
+project's **Approvals** list. To fix this problem, add the approval group as a shared group
+high enough in the shared hierarchy so the project requiring review inherits this
+group of users.
+
## Security Approvals **(ULTIMATE)**
> [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/357021) in GitLab 15.0.
diff --git a/doc/user/project/merge_requests/approvals/settings.md b/doc/user/project/merge_requests/approvals/settings.md
index a8acab3898b..1ab564c108b 100644
--- a/doc/user/project/merge_requests/approvals/settings.md
+++ b/doc/user/project/merge_requests/approvals/settings.md
@@ -87,8 +87,7 @@ to a merge request may or may not be able to approve the work:
[code owners](../../code_owners.md) who commit
to a merge request cannot approve it, when the merge request affects files they own.
-To learn more about the [differences between authors and committers](https://git-scm.com/book/en/v2/Git-Basics-Viewing-the-Commit-History),
-read the official Git documentation for an explanation.
+For more information, see the [official Git documentation](https://git-scm.com/book/en/v2/Git-Basics-Viewing-the-Commit-History).
## Prevent editing approval rules in merge requests
@@ -121,13 +120,17 @@ permission enables an electronic signature for approvals, such as the one define
## Remove all approvals when commits are added to the source branch
-By default, an approval on a merge request remains in place, even if you add more changes
-after the approval. If you want to remove all existing approvals on a merge request
-when more changes are added to it:
+By default, an approval on a merge request is removed when you add more changes
+after the approval. In GitLab Premium and higher tiers, to keep existing approvals
+after more changes are added to the merge request:
1. On the left sidebar, select **Settings > Merge requests**.
1. In the **Merge request approvals** section, scroll to **Approval settings** and
- select **Remove all approvals**.
+ clear the **Remove all approvals** checkbox.
+
+ NOTE:
+ This setting is not available in GitLab Free.
+
1. Select **Save changes**.
Approvals aren't removed when a merge request is [rebased from the UI](../methods/index.md#rebasing-in-semi-linear-merge-methods)
@@ -155,7 +158,7 @@ To do this:
You can require specific approvals if a merge request would result in a decline in code test
coverage.
-To learn more, see [Coverage check approval rule](../../../../ci/pipelines/settings.md#coverage-check-approval-rule).
+For more information, see [Coverage check approval rule](../../../../ci/pipelines/settings.md#coverage-check-approval-rule).
## Settings cascading
diff --git a/doc/user/project/merge_requests/changes.md b/doc/user/project/merge_requests/changes.md
index 07ee2ef90c4..8f6b1a32424 100644
--- a/doc/user/project/merge_requests/changes.md
+++ b/doc/user/project/merge_requests/changes.md
@@ -57,7 +57,7 @@ clear your browser's cookies or change this behavior again.
To view one file at a time for all of your merge requests:
-1. In the top-right corner, select your avatar.
+1. In the upper-right corner, select your avatar.
1. Select **Preferences**.
1. Scroll to the **Behavior** section and select the **Show one file at a time on merge request's Changes tab** checkbox.
1. Select **Save changes**.
diff --git a/doc/user/project/merge_requests/cherry_pick_changes.md b/doc/user/project/merge_requests/cherry_pick_changes.md
index 388c6fb55ac..9fac872ac4b 100644
--- a/doc/user/project/merge_requests/cherry_pick_changes.md
+++ b/doc/user/project/merge_requests/cherry_pick_changes.md
@@ -55,7 +55,7 @@ by the merge request:
1. On the top bar, select **Main menu > Projects** and find your project.
1. On the left sidebar, select **Merge requests**, and find your merge request.
1. Scroll to the merge request reports section, and find the **Merged by** report.
-1. In the top right, select **Cherry-pick**:
+1. In the upper right, select **Cherry-pick**:
![Cherry-pick merge request](img/cherry_pick_v15_4.png)
1. In the modal window, select the project and branch to cherry-pick into.
@@ -87,7 +87,7 @@ list of commits included in a merge request:
1. On the left sidebar, select **Merge requests**, and find your merge request.
1. In the merge request's secondary menu, select **Commits** to display the commit details page.
1. Select the title of the commit you want to cherry-pick.
-1. In the top right corner, select **Options > Cherry-pick** to show the cherry-pick modal.
+1. In the upper-right corner, select **Options > Cherry-pick** to show the cherry-pick modal.
1. In the modal window, select the project and branch to cherry-pick into.
1. Optional. Select **Start a new merge request with these changes**.
1. Select **Cherry-pick**.
@@ -101,7 +101,7 @@ when you view that file in your project's Git repository:
1. On the left sidebar, select **Repository > Files** and go to the file
changed by the commit.
1. Select **History**, then select the title of the commit you want to cherry-pick.
-1. In the top right corner, select **Options > Cherry-pick** to show the cherry-pick modal.
+1. In the upper-right corner, select **Options > Cherry-pick** to show the cherry-pick modal.
1. In the modal window, select the project and branch to cherry-pick into.
1. Optional. Select **Start a new merge request with these changes**.
1. Select **Cherry-pick**.
@@ -115,7 +115,7 @@ You can cherry-pick merge requests from the same project, or forks of the same
project, from the GitLab user interface:
1. In the merge request's secondary menu, select **Commits** to display the commit details page.
-1. In the top right corner, select **Options > Cherry-pick** to show the cherry-pick modal.
+1. In the upper-right corner, select **Options > Cherry-pick** to show the cherry-pick modal.
1. In **Pick into project** and **Pick into branch**, select the destination project and branch:
![Cherry-pick commit](img/cherry_pick_into_project_v13_11.png)
1. Optional. Select **Start a new merge request** if you're ready to create a merge request.
diff --git a/doc/user/project/merge_requests/commit_templates.md b/doc/user/project/merge_requests/commit_templates.md
index a14d8bddd24..f8c24e4067b 100644
--- a/doc/user/project/merge_requests/commit_templates.md
+++ b/doc/user/project/merge_requests/commit_templates.md
@@ -89,7 +89,7 @@ Commit message templates support these variables:
| `%{approved_by}` | Line-separated list of the merge request approvers in a `Approved-by` Git commit trailer format. | `Approved-by: Sidney Jones <sjones@example.com>` <br> `Approved-by: Zhang Wei <zwei@example.com>` |
| `%{merged_by}` | User who merged the merge request. | `Alex Garcia <agarcia@example.com>` |
| `%{co_authored_by}` | Names and emails of commit authors in a `Co-authored-by` Git commit trailer format. Limited to authors of 100 most recent commits in merge request. | `Co-authored-by: Zane Doe <zdoe@example.com>` <br> `Co-authored-by: Blake Smith <bsmith@example.com>` |
-| `%{all_commits}` | Messages from all commits in the merge request. Limited to 100 most recent commits. Skips commit bodies exceeding 100KiB and merge commit messages. | `* Feature introduced` <br><br> `This commit implements feature` <br> `Changelog:added` <br><br> `* Bug fixed` <br><br> `* Documentation improved` <br><br>`This commit introduced better docs.`|
+| `%{all_commits}` | Messages from all commits in the merge request. Limited to 100 most recent commits. Skips commit bodies exceeding 100 KiB and merge commit messages. | `* Feature introduced` <br><br> `This commit implements feature` <br> `Changelog:added` <br><br> `* Bug fixed` <br><br> `* Documentation improved` <br><br>`This commit introduced better docs.`|
Any line containing only an empty variable is removed. If the line to be removed is both
preceded and followed by an empty line, the preceding empty line is also removed.
diff --git a/doc/user/project/merge_requests/conflicts.md b/doc/user/project/merge_requests/conflicts.md
index 6063d64a721..932eec5e631 100644
--- a/doc/user/project/merge_requests/conflicts.md
+++ b/doc/user/project/merge_requests/conflicts.md
@@ -59,7 +59,8 @@ in the user interface, and you can also resolve conflicts locally through the co
To resolve less-complex conflicts from the GitLab user interface:
-1. Go to your merge request.
+1. On the top bar, select **Main menu > Projects** and find your project.
+1. On the left sidebar, select **Merge requests** and find the merge request.
1. Select **Overview**, and scroll to the merge request reports section.
1. Find the merge conflicts message, and select **Resolve conflicts**.
GitLab shows a list of files with merge conflicts. The conflicts are
@@ -83,7 +84,8 @@ Some merge conflicts are more complex, requiring you to manually modify lines to
resolve their conflicts. Use the merge conflict resolution editor to resolve complex
conflicts in the GitLab interface:
-1. Go to your merge request.
+1. On the top bar, select **Main menu > Projects** and find your project.
+1. On the left sidebar, select **Merge requests** and find the merge request.
1. Select **Overview**, and scroll to the merge request reports section.
1. Find the merge conflicts message, and select **Resolve conflicts**.
GitLab shows a list of files with merge conflicts.
diff --git a/doc/user/project/merge_requests/creating_merge_requests.md b/doc/user/project/merge_requests/creating_merge_requests.md
index 542edc11c44..875312bbb7c 100644
--- a/doc/user/project/merge_requests/creating_merge_requests.md
+++ b/doc/user/project/merge_requests/creating_merge_requests.md
@@ -19,7 +19,7 @@ You can create a merge request from the list of merge requests.
1. On the top bar, select **Main menu > Projects** and find your project.
1. On the left menu, select **Merge requests**.
-1. In the top right, select **New merge request**.
+1. In the upper right, select **New merge request**.
1. Select a source and target branch and then **Compare branches and continue**.
1. Fill out the fields and select **Create merge request**.
@@ -35,14 +35,14 @@ If your development workflow requires an issue for every merge
request, you can create a branch directly from the issue to speed the process up.
The new branch, and later its merge request, are marked as related to this issue.
After merging the merge request, the issue is closed automatically, unless [automatic issue closing is disabled](../issues/managing_issues.md#disable-automatic-issue-closing).
-You can see a **Create merge request** dropdown below the issue description.
+You can see a **Create merge request** dropdown list below the issue description.
NOTE:
In GitLab 14.8 and later, selecting **Create merge request**
[redirects to the merge request creation form](https://gitlab.com/gitlab-org/gitlab/-/issues/349566)
instead of immediately creating the merge request.
-The **Create merge request** button doesn't display if:
+**Create merge request** doesn't display if:
- A branch with the same name already exists.
- A merge request already exists for this branch.
@@ -54,15 +54,14 @@ To make this button appear, one possible workaround is to
After removal, the fork relationship cannot be restored. This project can no longer
be able to receive or send merge requests to the source project, or other forks.
-This dropdown contains the options **Create merge request and branch** and **Create branch**.
+The dropdown list contains the options **Create merge request and branch** and **Create branch**.
After selecting one of these options, a new branch or branch and merge request
is created based on your project's [default branch](../repository/branches/default.md).
-The branch name is based on an internal ID, and the issue title. The example
-screenshot above creates a branch named
-`2-make-static-site-auto-deploy-and-serve`.
+The branch name is based on your project's branch name template. The default template
+is `%{id}-%{title}`. Supported variables for branch name templates are `%{id}` and `%{title}`.
-When you select the **Create branch** button in an empty
+When you select **Create branch** in an empty
repository project, GitLab performs these actions:
- Creates a default branch.
@@ -82,7 +81,7 @@ merge request is merged.
You can create a merge request when you add, edit, or upload a file to a repository.
-1. Add, edit, or upload a file to the repository.
+1. [Add, edit, or upload](../repository/web_editor.md) a file to the repository.
1. In the **Commit message**, enter a reason for the commit.
1. Select the **Target branch** or create a new branch by typing the name (without spaces, capital letters, or special chars).
1. Select the **Start a new merge request with these changes** checkbox or toggle. This checkbox or toggle is visible only
@@ -172,7 +171,7 @@ To create a merge request by sending an email:
1. On the top bar, select **Main menu > Projects** and find your project.
1. On the left menu, select **Merge requests**.
-1. In the top right, select **Email a new merge request to this project**.
+1. In the upper right, select **Email a new merge request to this project**.
An email address is displayed. Copy this address.
Ensure you keep this address private.
1. Open an email and compose a message with the following information:
diff --git a/doc/user/project/merge_requests/csv_export.md b/doc/user/project/merge_requests/csv_export.md
index 662189c5e40..9028a9411ea 100644
--- a/doc/user/project/merge_requests/csv_export.md
+++ b/doc/user/project/merge_requests/csv_export.md
@@ -14,7 +14,7 @@ To export merge requests to a CSV file:
1. On the top bar, select **Main menu > Projects** and find your project.
1. On the left sidebar, select **Merge requests** .
-1. Add any searches or filters. This can help you keep the size of the CSV file under the 15MB limit. The limit ensures
+1. Add any searches or filters. This can help you keep the size of the CSV file under the 15 MB limit. The limit ensures
the file can be emailed to a variety of email providers.
1. Select **Export as CSV** (**{export}**).
1. Confirm the correct number of merge requests are to be exported.
diff --git a/doc/user/project/merge_requests/drafts.md b/doc/user/project/merge_requests/drafts.md
index 0bc9b337e3b..62820988701 100644
--- a/doc/user/project/merge_requests/drafts.md
+++ b/doc/user/project/merge_requests/drafts.md
@@ -21,12 +21,13 @@ the **Merge** button until you remove the **Draft** flag:
> - [Removed](https://gitlab.com/gitlab-org/gitlab/-/issues/228685) all support for using **WIP** in GitLab 14.8.
> - **Mark as draft** and **Mark as ready** buttons [introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/227421) in GitLab 13.5.
> `/draft` quick action as a toggle [deprecated](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/92654) in GitLab 15.4.
+> - [Changed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/108073) the draft status to use a checkbox in GitLab 15.8.
There are several ways to flag a merge request as a draft:
-- **Viewing a merge request**: In the top right corner of the merge request, select **Mark as draft**.
+- **Viewing a merge request**: In the upper-right corner of the merge request, select **Mark as draft**.
- **Creating or editing a merge request**: Add `[Draft]`, `Draft:` or `(Draft)` to
- the beginning of the merge request's title, or select **Start the title with Draft:**
+ the beginning of the merge request's title, or select **Mark as draft**
below the **Title** field.
- **Commenting in an existing merge request**: Add the `/draft`
[quick action](../quick_actions.md#issues-merge-requests-and-epics)
@@ -40,14 +41,14 @@ There are several ways to flag a merge request as a draft:
When a merge request is ready to be merged, you can remove the `Draft` flag in several ways:
-- **Viewing a merge request**: In the top right corner of the merge request, select **Mark as ready**.
+- **Viewing a merge request**: In the upper-right corner of the merge request, select **Mark as ready**.
Users with at least the Developer role
can also scroll to the bottom of the merge request description and select **Mark as ready**:
![Mark as ready](img/draft_blocked_merge_button_v13_10.png)
- **Editing an existing merge request**: Remove `[Draft]`, `Draft:` or `(Draft)`
- from the beginning of the title, or select **Remove the Draft: prefix from the title**
+ from the beginning of the title, or clear **Mark as draft**
below the **Title** field.
- **Commenting in an existing merge request**: Add the `/ready`
[quick action](../quick_actions.md#issues-merge-requests-and-epics)
diff --git a/doc/user/project/merge_requests/getting_started.md b/doc/user/project/merge_requests/getting_started.md
index 58750cdf5bc..4125d8e8fdb 100644
--- a/doc/user/project/merge_requests/getting_started.md
+++ b/doc/user/project/merge_requests/getting_started.md
@@ -1,147 +1,11 @@
---
-stage: Create
-group: Code Review
-info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/product/ux/technical-writing/#assignments
-description: "Getting started with merge requests."
+redirect_to: 'index.md'
+remove_date: '2023-03-31'
---
-# Getting started with merge requests **(FREE)**
+This document was moved to [another location](index.md).
-A merge request (**MR**) is the basis of GitLab as a tool for code
-collaboration and version control.
-
-When working in a Git-based platform, you can use branching
-strategies to collaborate on code.
-
-A repository is composed by its _default branch_, which contains
-the major version of the codebase, from which you create minor
-branches, also called _feature branches_, to propose changes to
-the codebase without introducing them directly into the major
-version of the codebase.
-
-Branching is especially important when collaborating with others,
-avoiding changes to be pushed directly to the default branch
-without prior reviews, tests, and approvals.
-
-When you create a new feature branch, change the files, and push
-it to GitLab, you have the option to create a **merge request**,
-which is essentially a _request_ to merge one branch into another.
-
-The branch you added your changes into is called _source branch_
-while the branch you request to merge your changes into is
-called _target branch_.
-
-The target branch can be the default or any other branch, depending
-on the branching strategies you choose.
-
-In a merge request, beyond visualizing the differences between the
-original content and your proposed changes, you can execute a
-[significant number of tasks](#what-you-can-do-with-merge-requests)
-before concluding your work and merging the merge request.
-
-You can watch our [GitLab Flow video](https://www.youtube.com/watch?v=InKNIvky2KE) for
-a quick overview of working with merge requests.
-
-## What you can do with merge requests
-
-When you start a new merge request, you can immediately include the following
-options. You can also add them later by either selecting **Edit** on the merge
-request's page at the top-right side, or by using
-[keyboard shortcuts for merge requests](../../shortcuts.md#merge-requests):
-
-- [Assign](index.md#assign-a-user-to-a-merge-request) the merge request to a colleague for review. With [multiple assignees](index.md#assign-multiple-users), you can assign it to more than one person at a time.
-- Set a [milestone](../milestones/index.md) to track time-sensitive changes.
-- Add [labels](../labels.md) to help contextualize and filter your merge requests over time.
-- [Require approval](approvals/index.md#required-approvals) from your team.
-- [Close issues automatically](#merge-requests-to-close-issues) when they are merged.
-- Enable the [delete source branch when merge request is accepted](#deleting-the-source-branch) option to keep your repository clean.
-- Enable the [squash commits when merge request is accepted](squash_and_merge.md) option to combine all the commits into one before merging, thus keep a clean commit history in your repository.
-- Set the merge request as a [**Draft**](drafts.md) to avoid accidental merges before it is ready.
-
-After you have created the merge request, you can also:
-
-- [Discuss](../../discussions/index.md) your implementation with your team in the merge request thread.
-- [Perform inline code reviews](reviews/index.md).
-- Add [merge request dependencies](dependencies.md) to restrict it to be merged only when other merge requests have been merged.
-- Preview continuous integration [pipelines on the merge request widget](widgets.md).
-- Preview how your changes look directly on your deployed application with [Review Apps](widgets.md#live-preview-with-review-apps).
-- [Allow collaboration on merge requests across forks](allow_collaboration.md).
-- Perform a [Review](reviews/index.md) to create multiple comments on a diff and publish them when you're ready.
-- Add [code suggestions](reviews/suggestions.md) to change the content of merge requests directly into merge request threads, and easily apply them to the codebase directly from the UI.
-- Add a time estimation and the time spent with that merge request with [Time Tracking](../time_tracking.md#time-tracking).
-
-Many of these options can be set:
-
-- From the merge request page, with [keyboard shortcuts](../../shortcuts.md#merge-requests).
-- When pushing changes from the command line, with [Git push options](../push_options.md).
-
-See also other [features associated to merge requests](reviews/index.md#associated-features).
-
-### Reviewer
-
-WARNING:
-Requesting a code review is an important part of contributing code. However, deciding who should review
-your code and asking for a review are no easy tasks. Using the "assignee" field for both authors and
-reviewers makes it hard for others to determine who's doing what on a merge request.
-
-The merge request Reviewers feature enables you to request a review of your work, and
-see the status of the review. Reviewers help distinguish the roles of the users
-involved in the merge request. In comparison to an **Assignee**, who is directly
-responsible for creating or merging a merge request, a **Reviewer** is a team member
-who may only be involved in one aspect of the merge request, such as a peer review.
-
-To request a review of a merge request, expand the **Reviewers** select box in
-the right-hand sidebar. Search for the users you want to request a review from.
-When selected, GitLab creates a [to-do list item](../../todos.md) for each reviewer.
-
-To learn more, read [Review a merge request](reviews/index.md).
-
-### Merge requests to close issues
-
-To create a merge request to close an issue when it's merged, you can either:
-
-- [Add a note in the MR description](../issues/managing_issues.md#closing-issues-automatically).
-- In the issue, select **Create a merge request**. Then, you can either:
-
- - Create a new branch and [a draft merge request](../merge_requests/drafts.md)
- in one action. The branch is named `issuenumber-title` by default, but you can
- choose any name, and GitLab verifies that it's not already in use. The merge request
- inherits the milestone and labels of the issue, and is set to automatically
- close the issue when it is merged.
- - Create a [new branch](creating_merge_requests.md#from-an-issue)
- only, with its name starting with the issue number.
-
-If the issue is [confidential](../issues/confidential_issues.md),
-you may want to use a different workflow for
-[merge requests for confidential issues](confidential.md)
-to prevent confidential information from being exposed.
-
-### Deleting the source branch
-
-When creating a merge request, select the
-**Delete source branch when merge request accepted** option, and the source
-branch is deleted when the merge request is merged. To make this option
-enabled by default for all new merge requests, enable it in the
-[project's settings](../settings/index.md#configure-merge-request-settings-for-a-project).
-
-This option is also visible in an existing merge request next to
-the merge request button and can be selected or cleared before merging.
-It is only visible to users with the Maintainer role
-in the source project.
-
-If the user viewing the merge request does not have the correct
-permissions to delete the source branch and the source branch
-is set for deletion, the merge request widget displays the
-**Deletes source branch** text.
-
-![Delete source branch status](img/remove_source_branch_status.png)
-
-## Recommendations and best practices for merge requests
-
-- When working locally in your branch, add multiple commits and only push when
- you're done, so GitLab runs only one pipeline for all the commits pushed
- at once. By doing so, you save CI/CD minutes.
-- Delete feature branches on merge or after merging them to keep your repository clean.
-- Take one thing at a time and ship the smallest changes possible. By doing so,
- reviews are faster and your changes are less prone to errors.
-- Do not use capital letters nor special chars in branch names.
+<!-- This redirect file can be deleted after <2023-03-31>. -->
+<!-- Redirects that point to other docs in the same project expire in three months. -->
+<!-- Redirects that point to docs in a different project or site (for example, link is not relative and starts with `https:`) expire in one year. -->
+<!-- Before deletion, see: https://docs.gitlab.com/ee/development/documentation/redirects.html -->
diff --git a/doc/user/project/merge_requests/index.md b/doc/user/project/merge_requests/index.md
index 21651fd645c..a633366cc62 100644
--- a/doc/user/project/merge_requests/index.md
+++ b/doc/user/project/merge_requests/index.md
@@ -7,8 +7,9 @@ type: index, reference
# Merge requests **(FREE)**
-Merge requests (MRs) are the way you check source code changes into a branch.
-When you open a merge request, you can visualize and collaborate on the code changes before merge.
+To incorporate changes from a source branch to a target branch, you use a *merge request* (MR).
+
+When you open a merge request, you can visualize and collaborate on the changes before merge.
Merge requests include:
- A description of the request.
@@ -17,7 +18,9 @@ Merge requests include:
- A comment section for discussion threads.
- The list of commits.
-Read more about [how to get started](getting_started.md).
+<i class="fa fa-youtube-play youtube" aria-hidden="true"></i>
+For a quick overview of merge requests,
+view [this GitLab Flow video](https://www.youtube.com/watch?v=InKNIvky2KE).
## Create a merge request
@@ -62,7 +65,7 @@ or:
or:
-1. On the top bar, on the top right, select **{merge-request-open}** **Merge requests**.
+1. On the top bar, in the upper right, select **{merge-request-open}** **Merge requests**.
1. From the dropdown list, select **Assigned to you**.
## Filter the list of merge requests
@@ -205,6 +208,15 @@ To delete a merge request:
1. Go to the merge request you want to delete, and select **Edit**.
1. Scroll to the bottom of the page, and select **Delete merge request**.
+### Delete the source branch on merge
+
+You can delete the source branch for a merge request:
+
+- When you create a merge request, by selecting **Delete source branch when merge request accepted**.
+- When you merge a merge request, if you have the Maintainer role, by selecting **Delete source branch**.
+
+An administrator can make this option the default in the project's settings.
+
### Update merge requests when target branch merges **(FREE SELF)**
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/320902) in GitLab 13.9.
@@ -243,10 +255,10 @@ like in https://gitlab.com/gitlab-org/gitlab/-/merge_requests/87727/diffs?diff_i
FLAG:
On self-managed GitLab, by default this feature is not available. To make it available per project or for your entire instance, ask an administrator to [enable the feature flag](../../../administration/feature_flags.md) named `moved_mr_sidebar`.
-On GitLab.com, this feature is not available.
+On GitLab.com, this feature is enabled in the following projects: `gitlab-org/gitlab`, `gitlab-com/www-gitlab-com`, and `gitlab-org/customers-gitlab-com`.
When this feature flag is enabled, you can find the following actions in
-**Merge request actions** (**{ellipsis_v}**) on the top right:
+**Merge request actions** (**{ellipsis_v}**) in the upper right:
- The [notifications](../../profile/notifications.md#edit-notification-settings-for-issues-merge-requests-and-epics) toggle
- Mark merge request as ready or [draft](../merge_requests/drafts.md)
@@ -366,5 +378,5 @@ with a backup of the instance ready to be restored, just in case.
u = User.find_by_username('<username>')
p = Project.find_by_full_path('<namespace/project>')
m = p.merge_requests.find_by(iid: <iid>)
-Issuable::DestroyService.new(project: m.project, current_user: u).execute(m)
+Issuable::DestroyService.new(container: m.project, current_user: u).execute(m)
```
diff --git a/doc/user/project/merge_requests/methods/index.md b/doc/user/project/merge_requests/methods/index.md
index b1d07a740bf..1f7e15ee982 100644
--- a/doc/user/project/merge_requests/methods/index.md
+++ b/doc/user/project/merge_requests/methods/index.md
@@ -199,7 +199,7 @@ In these merge methods, you can merge only when your source branch is up-to-date
If a fast-forward merge is not possible but a conflict-free rebase is possible,
GitLab provides:
-- The [`/rebase` quick action](../../../../topics/git/git_rebase.md#rebase-from-the-gitlab-ui).
+- The [`/rebase` quick action](../../../../topics/git/git_rebase.md#from-the-gitlab-ui).
- The option to select **Rebase** in the user interface.
You must rebase the source branch locally before a fast-forward merge if both
diff --git a/doc/user/project/merge_requests/revert_changes.md b/doc/user/project/merge_requests/revert_changes.md
index 76f351f1346..5878873f209 100644
--- a/doc/user/project/merge_requests/revert_changes.md
+++ b/doc/user/project/merge_requests/revert_changes.md
@@ -62,7 +62,7 @@ To do this:
1. If you don't know the merge request the commit originated from:
1. On the left sidebar, select **Repository > Commits**.
1. Select the title of the commit to display full information about the commit.
-1. In the top right corner, select **Options**, then select **Revert**.
+1. In the upper-right corner, select **Options**, then select **Revert**.
1. In **Revert in branch**, select the branch to revert your changes into.
1. Optional. Select **Start a new merge request** to start a new merge request with the new revert commit.
1. Select **Revert**.
diff --git a/doc/user/project/merge_requests/reviews/data_usage.md b/doc/user/project/merge_requests/reviews/data_usage.md
index f17015aef4e..dd07f0b4a6e 100644
--- a/doc/user/project/merge_requests/reviews/data_usage.md
+++ b/doc/user/project/merge_requests/reviews/data_usage.md
@@ -15,21 +15,21 @@ Suggested Reviewers is the first user-facing GitLab machine learning (ML) powere
When a Project Maintainer or Owner enables Suggested Reviewers in project settings GitLab kicks off a data extraction job for the project which leverages the Merge Request API to understand pattern of review including recency, domain experience, and frequency to suggest an appropriate reviewer.
-This data extraction job can take a few hours to complete (possibly up to a day), which is largely dependent on the size of the project. The process is automated and no action is needed during this process. Once data extraction is complete, you will start getting suggestions in merge requests.
+This data extraction job can take a few hours to complete (possibly up to a day), which is largely dependent on the size of the project. The process is automated and no action is needed during this process. Once data extraction is complete, you start getting suggestions in merge requests.
### Generating suggestions
-Once Suggested Reviewers is enabled and the data extraction is complete, new merge requests or new commits to existing merge requests will automatically trigger a Suggested Reviewers ML model inference and generate up to 5 suggested reviewers. These suggestions are contextual to the changes in the merge request. Additional commits to merge requests may change the reviewer suggestions which will automatically update in the reviewer dropdown list.
+Once Suggested Reviewers is enabled and the data extraction is complete, new merge requests or new commits to existing merge requests automatically trigger a Suggested Reviewers ML model inference and generate up to 5 suggested reviewers. These suggestions are contextual to the changes in the merge request. Additional commits to merge requests may change the reviewer suggestions, which are automatically updated in the reviewer dropdown list.
## Progressive enhancement
-This feature is designed as a progressive enhancement to the existing GitLab Reviewers functionality. The GitLab Reviewer UI will only offer suggestions if the ML engine is able to provide a recommendation. In the event of an issue or model inference failure, the feature will gracefully degrade. At no point with the usage of Suggested Reviewers prevent a user from being able to manually set a reviewer.
+This feature is designed as a progressive enhancement to the existing GitLab Reviewers functionality. The GitLab Reviewer UI only offers suggestions if the ML engine is able to provide a recommendation. In the event of an issue or model inference failure, the feature gracefully degrades. At no point with the usage of Suggested Reviewers prevent a user from being able to manually set a reviewer.
## Model Accuracy
-Organizations use many different processes for code review. Some focus on senior engineers reviewing junior engineer's code, others have hierarchical organizational structure based reviews. Suggested Reviewers is focused on contextual reviewers based on historical merge request activity by users. While we will continue evolving the underlying ML model to better serve various code review use cases and processes Suggested Reviewers does not replace the usage of other code review features like Code Owners and [Approval Rules](../approvals/rules.md). Reviewer selection is highly subjective therefore, we do not expect Suggested Reviewers to provide perfect suggestions every time.
+Organizations use many different processes for code review. Some focus on senior engineers reviewing junior engineer's code, others have hierarchical organizational structure based reviews. Suggested Reviewers is focused on contextual reviewers based on historical merge request activity by users. While we continue evolving the underlying ML model to better serve various code review use cases and processes Suggested Reviewers does not replace the usage of other code review features like Code Owners and [Approval Rules](../approvals/rules.md). Reviewer selection is highly subjective therefore, we do not expect Suggested Reviewers to provide perfect suggestions every time.
-Through analysis of beta customer usage, we find that the Suggested Reviewers ML model provides suggestions that are adopted in 60% of cases. We will be introducing a feedback mechanism into the Suggested Reviewers feature in the future to allow users to flag bad reviewer suggestions to help improve the model. Additionally we will be offering an opt-in feature in the future which will allow the model to use your project's data for training the underlying model.
+Through analysis of beta customer usage, we find that the Suggested Reviewers ML model provides suggestions that are adopted in 60% of cases. We plan to introduce a feedback mechanism into the Suggested Reviewers feature in the future to allow users to flag bad reviewer suggestions to help improve the model. Additionally we plan to offer an opt-in feature in the future which allows the model to use your project's data for training the underlying model.
## Off by default
diff --git a/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v13_8.png b/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v13_8.png
deleted file mode 100644
index c2aa0689d65..00000000000
--- a/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v13_8.png
+++ /dev/null
Binary files differ
diff --git a/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v15_9.png b/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v15_9.png
new file mode 100644
index 00000000000..6839c675625
--- /dev/null
+++ b/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_form_v15_9.png
Binary files differ
diff --git a/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v13_8.png b/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v13_8.png
deleted file mode 100644
index 3828868965b..00000000000
--- a/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v13_8.png
+++ /dev/null
Binary files differ
diff --git a/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v15_9.png b/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v15_9.png
new file mode 100644
index 00000000000..c7942d1e36d
--- /dev/null
+++ b/doc/user/project/merge_requests/reviews/img/reviewer_approval_rules_sidebar_v15_9.png
Binary files differ
diff --git a/doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_4.png b/doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_4.png
deleted file mode 100644
index aae75b0736c..00000000000
--- a/doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_4.png
+++ /dev/null
Binary files differ
diff --git a/doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_9.png b/doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_9.png
new file mode 100644
index 00000000000..70db0d79eaf
--- /dev/null
+++ b/doc/user/project/merge_requests/reviews/img/suggested_reviewers_v15_9.png
Binary files differ
diff --git a/doc/user/project/merge_requests/reviews/index.md b/doc/user/project/merge_requests/reviews/index.md
index 9a75c038dbc..5291a845437 100644
--- a/doc/user/project/merge_requests/reviews/index.md
+++ b/doc/user/project/merge_requests/reviews/index.md
@@ -25,21 +25,27 @@ review merge requests in Visual Studio Code.
> [Introduced](https://gitlab.com/groups/gitlab-org/modelops/applied-ml/review-recommender/-/epics/3) in GitLab 15.4.
-GitLab can recommend reviewers with Suggested Reviewers. Using the changes in a merge request and a project's contribution graph, machine learning powered suggestions appear in the reviewer section of the right merge request sidebar.
+GitLab can suggest reviewers. Using the changes in a merge request and a project's contribution graph, machine learning suggestions appear in the reviewer section of the right sidebar.
-![Suggested Reviewers](img/suggested_reviewers_v15_4.png)
+![Suggested Reviewers](img/suggested_reviewers_v15_9.png)
This feature is currently in [Open Beta](https://about.gitlab.com/handbook/product/gitlab-the-product/#open-beta) behind a [feature flag](https://gitlab.com/gitlab-org/gitlab/-/issues/368356).
-Learn more about [how suggested reviewers works and data privacy](data_usage.md).
+For more information, see [Data usage in Suggested Reviewers](data_usage.md).
### Enable suggested reviewers
-Project Maintainers or Owners can enable suggested reviewers by visiting the [project settings](../../settings/index.md).
+Project Maintainers or Owners can enable suggested reviewers by visiting
+the [project settings](../../settings/index.md).
-Enabling suggested reviewers will trigger GitLab to create an ML model for your project that will be used to generate reviewers. The larger your project, the longer this can take, but usually, the model will be ready to generate suggestions within a few hours.
+Enabling suggested reviewers triggers GitLab to create an ML model for your
+project that is used to generate reviewers. The larger your project, the longer
+this process can take. Usually, the model is ready to generate suggestions
+within a few hours.
-No action is required once the feature is enabled. Once the model is ready, recommendations will populate the Reviewer dropdown list in the right-hand sidebar of a merge request with new commits.
+No action is required after the feature is enabled. After the model is ready,
+recommendations populate the **Reviewer** dropdown list in the right-hand sidebar
+of a merge request with new commits.
## Review a merge request
@@ -51,8 +57,8 @@ to you. When you're ready, you can publish them together in a single action.
To start your review:
1. Go to the merge request you want to review, and select the **Changes** tab.
- To learn more about navigating the diffs displayed in this tab, read
- [Changes tab in merge requests](../changes.md).
+ For more information about navigating the diffs displayed in this tab, see
+ [Changes in merge requests](../changes.md).
1. Select the **{comment}** **comment** icon in the gutter to expand the diff lines
and display a comment box. In GitLab version 13.2 and later, you can
[select multiple lines](#comment-on-multiple-lines).
@@ -78,7 +84,7 @@ To download the changes included in a merge request as a diff:
1. On the top bar, select **Main menu > Projects** and find your project.
1. On the left sidebar, select **Merge requests**.
1. Select your merge request.
-1. On the top right, select **Code > Plain diff**.
+1. In the upper right, select **Code > Plain diff**.
If you know the URL of the merge request, you can also download the diff from
the command line by appending `.diff` to the URL. This example downloads the diff
@@ -101,7 +107,7 @@ To download the changes included in a merge request as a patch file:
1. On the top bar, select **Main menu > Projects** and find your project.
1. On the left sidebar, select **Merge requests**.
1. Select your merge request.
-1. On the top right, select **Code > Email patches**.
+1. In the upper right, select **Code > Email patches**.
If you know the URL of the merge request, you can also download the patch from
the command line by appending `.patch` to the URL. This example downloads the patch
@@ -147,7 +153,7 @@ To resolve or unresolve a thread when replying to a comment:
Pending comments display information about the action to be taken when the comment is published:
-- **{check-circle-filled}** Thread will be resolved.
+- **{check-circle-filled}** Thread is resolved.
- **{check-circle}** Thread stays unresolved.
### Add a new comment
@@ -170,11 +176,11 @@ below the name of each suggested reviewer. [Code Owners](../../code_owners.md) a
This example shows reviewers and approval rules when creating a new merge request:
-![Reviewer approval rules in new/edit form](img/reviewer_approval_rules_form_v13_8.png)
+![Reviewer approval rules in new/edit form](img/reviewer_approval_rules_form_v15_9.png)
This example shows reviewers and approval rules in a merge request sidebar:
-![Reviewer approval rules in sidebar](img/reviewer_approval_rules_sidebar_v13_8.png)
+![Reviewer approval rules in sidebar](img/reviewer_approval_rules_sidebar_v15_9.png)
### Request a new review
@@ -194,7 +200,7 @@ them a notification email.
## Comment on multiple lines
> - [Introduced](https://gitlab.com/gitlab-org/ux-research/-/issues/870) in GitLab 13.2.
-> - [Added](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/49875) click-and-drag features in GitLab 13.8.
+> - [Added](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/49875) select-and-drag features in GitLab 13.8.
> - [Feature flag removed](https://gitlab.com/gitlab-org/gitlab/-/issues/299121) in GitLab 13.9.
When commenting on a diff, you can select which lines of code your comment refers
diff --git a/doc/user/project/merge_requests/status_checks.md b/doc/user/project/merge_requests/status_checks.md
index 2894b71e7e6..62a2baa049b 100644
--- a/doc/user/project/merge_requests/status_checks.md
+++ b/doc/user/project/merge_requests/status_checks.md
@@ -22,25 +22,23 @@ respond with an associated status. This status is then displayed as a non-blocki
widget within the merge request to surface this status to the merge request author or reviewers
at the merge request level itself.
-The lack of a status check response does not block the merging of a merge request.
-
You can configure merge request status checks for each individual project. These are not shared between projects.
-To learn more about use cases, feature discovery, and development timelines,
-see the [external status checks epic](https://gitlab.com/groups/gitlab-org/-/epics/3869).
+For more information about use cases, feature discovery, and development timelines,
+see [epic 3869](https://gitlab.com/groups/gitlab-org/-/epics/3869).
## Block merges of merge requests unless all status checks have passed
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/369859) in GitLab 15.5 [with a flag](../../../administration/feature_flags.md) named `only_allow_merge_if_all_status_checks_passed`. Disabled by default.
> - [Enabled on GitLab.com](https://gitlab.com/gitlab-org/gitlab/-/issues/372340) in GitLab 15.8.
+> - Enabled on self-managed and feature flag [removed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/111492) in GitLab 15.9.
-FLAG:
-On self-managed GitLab, by default this feature is not available. To make it available per project or for your entire instance, ask an administrator to
-[enable the feature flag](../../../administration/feature_flags.md) named `only_allow_merge_if_all_status_checks_passed`. On GitLab.com, this feature is available but can be configured by GitLab.com administrators only.
+By default, merge requests in projects can be merged even if external status checks fail. To block the merging of merge requests when external checks fail:
-By default, merge requests in projects can be merged even if external status checks fail. To block the merging of merge requests when external checks fail, enable this feature
-using the [project API](../../../api/projects.md#edit-project). You must also [enable the feature flag](../../../administration/feature_flags.md) named
-`only_allow_merge_if_all_status_checks_passed` on self-managed GitLab.
+1. On the top bar, select **Main menu > Projects** and find your project.
+1. On the left sidebar, select **Settings > Merge requests**.
+1. Select the **Status checks must succeed** checkbox.
+1. Select **Save changes**.
## Lifecycle
@@ -63,7 +61,7 @@ Merge requests return a `409 Conflict` error to any responses that do not refer
External status checks have the following states:
-- `pending` - The default state. No response can been received by the merge request from the external service.
+- `pending` - The default state. No response has been received by the merge request from the external service.
- `passed` - A response from the external service has been received and approved by it.
- `failed` - A response from the external service has been received and denied by it.
@@ -146,7 +144,7 @@ The **Remove status check?** modal is then shown.
To complete the deletion of the status check you must select the
**Remove status check** button. This **permanently** deletes
-the status check and it **will not** be recoverable.
+the status check and it **is not** recoverable.
## Status checks widget