Skip to content

Commit bc06e9c

Browse files
author
Marcia Ramos
committed
Merge branch 'docs/add_file_diff_description' into 'master'
Docs: explain what is a diff Closes #62072 See merge request gitlab-org/gitlab-ce!32560
2 parents 78174ec + 779b1f7 commit bc06e9c

File tree

3 files changed

+22
-0
lines changed

3 files changed

+22
-0
lines changed

doc/user/admin_area/diff_limits.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ type: reference
66

77
You can set a maximum size for display of diff files (patches).
88

9+
For details about diff files, [View changes between files](../project/merge_requests/index.md#view-changes-between-file-versions).
10+
911
## Maximum diff patch size
1012

1113
Diff files which exceed this value will be presented as 'too large' and won't
Loading

doc/user/project/merge_requests/index.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,26 @@ you hide threads that are no longer relevant.
164164

165165
[Read more about resolving threads in merge requests reviews.](../../discussions/index.md)
166166

167+
## View changes between file versions
168+
169+
The **Changes** tab of a merge request shows the changes to files between branches or
170+
commits. This view of changes to a file is also known as a **diff**. By default, the diff view
171+
compares the file in the merge request branch and the file in the target branch.
172+
173+
The diff view includes the following:
174+
175+
- The file's name and path.
176+
- The number of lines added and deleted.
177+
- Buttons for the following options:
178+
- Toggle comments for this file; useful for inline reviews.
179+
- Edit the file in the merge request's branch.
180+
- Show full file, in case you want to look at the changes in context with the rest of the file.
181+
- View file at the current commit.
182+
- Preview the changes with [Review Apps](../../../ci/review_apps/index.md).
183+
- The changed lines, with the specific changes highlighted.
184+
185+
![Example screenshot of a source code diff](img/merge_request_diff_v12_2.png)
186+
167187
## Commenting on any file line in merge requests
168188

169189
> [Introduced](https://gitlab.com/gitlab-org/gitlab-ce/issues/13950) in GitLab 11.5.

0 commit comments

Comments
 (0)