Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
9516bcd3
Commit
9516bcd3
authored
Sep 06, 2019
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab-ce master
parents
f3dba6b2
222d9e62
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
37 additions
and
9 deletions
+37
-9
app/views/projects/merge_requests/_how_to_merge.html.haml
app/views/projects/merge_requests/_how_to_merge.html.haml
+9
-8
changelogs/unreleased/quote-branch-names-in-instructions.yml
changelogs/unreleased/quote-branch-names-in-instructions.yml
+5
-0
doc/user/admin_area/diff_limits.md
doc/user/admin_area/diff_limits.md
+2
-0
doc/user/project/merge_requests/img/merge_request_diff_v12_2.png
...r/project/merge_requests/img/merge_request_diff_v12_2.png
+0
-0
doc/user/project/merge_requests/index.md
doc/user/project/merge_requests/index.md
+20
-0
spec/features/merge_request/user_selects_branches_for_new_mr_spec.rb
...es/merge_request/user_selects_branches_for_new_mr_spec.rb
+1
-1
No files found.
app/views/projects/merge_requests/_how_to_merge.html.haml
View file @
9516bcd3
...
...
@@ -13,12 +13,13 @@
%pre
.dark
#merge-info-1
-
if
@merge_request
.
for_fork?
:preserve
git fetch
#{
h
default_url_to_repo
(
@merge_request
.
source_project
)
}
#{
h
@merge_request
.
source_branch
}
git checkout -b
#{
h
@merge_request
.
source_project_path
}
-
#{
h
@merge_request
.
source_branch
}
FETCH_HEAD
-# All repo/branch refs have been quoted to allow support for special characters (such as #my-branch)
git fetch "
#{
h
default_url_to_repo
(
@merge_request
.
source_project
)
}
" "
#{
h
@merge_request
.
source_branch
}
"
git checkout -b "
#{
h
@merge_request
.
source_project_path
}
-
#{
h
@merge_request
.
source_branch
}
" FETCH_HEAD
-
else
:preserve
git fetch origin
git checkout -b
#{
h
@merge_request
.
source_branch
}
origin/
#{
h
@merge_request
.
source_branch
}
git checkout -b
"
#{
h
@merge_request
.
source_branch
}
" "origin/
#{
h
@merge_request
.
source_branch
}
"
%p
%strong
Step 2.
Review the changes locally
...
...
@@ -31,20 +32,20 @@
-
if
@merge_request
.
for_fork?
:preserve
git fetch origin
git checkout
origin/
#{
h
@merge_request
.
target_branch
}
git merge --no-ff
#{
h
@merge_request
.
source_project_path
}
-
#{
h
@merge_request
.
source_branch
}
git checkout
"origin/
#{
h
@merge_request
.
target_branch
}
"
git merge --no-ff
"
#{
h
@merge_request
.
source_project_path
}
-
#{
h
@merge_request
.
source_branch
}
"
-
else
:preserve
git fetch origin
git checkout
origin/
#{
h
@merge_request
.
target_branch
}
git merge --no-ff
#{
h
@merge_request
.
source_branch
}
git checkout
"origin/
#{
h
@merge_request
.
target_branch
}
"
git merge --no-ff
"
#{
h
@merge_request
.
source_branch
}
"
%p
%strong
Step 4.
Push the result of the merge to GitLab
=
clipboard_button
(
target:
"pre#merge-info-4"
,
title:
"Copy commands to clipboard"
)
%pre
.dark
#merge-info-4
:preserve
git push origin
#{
h
@merge_request
.
target_branch
}
git push origin
"
#{
h
@merge_request
.
target_branch
}
"
-
unless
@merge_request
.
can_be_merged_by?
(
current_user
)
%p
Note that pushing to GitLab requires write access to this repository.
...
...
changelogs/unreleased/quote-branch-names-in-instructions.yml
0 → 100644
View file @
9516bcd3
---
title
:
Quote branch names in how to merge instructions
merge_request
:
32639
author
:
Lee Tickett
type
:
fixed
doc/user/admin_area/diff_limits.md
View file @
9516bcd3
...
...
@@ -6,6 +6,8 @@ type: reference
You can set a maximum size for display of diff files (patches).
For details about diff files,
[
View changes between files
](
../project/merge_requests/index.md#view-changes-between-file-versions
)
.
## Maximum diff patch size
Diff files which exceed this value will be presented as 'too large' and won't
...
...
doc/user/project/merge_requests/img/merge_request_diff_v12_2.png
0 → 100644
View file @
9516bcd3
133 KB
doc/user/project/merge_requests/index.md
View file @
9516bcd3
...
...
@@ -164,6 +164,26 @@ you hide threads that are no longer relevant.
[
Read more about resolving threads in merge requests reviews.
](
../../discussions/index.md
)
## View changes between file versions
The
**Changes**
tab of a merge request shows the changes to files between branches or
commits. This view of changes to a file is also known as a
**diff**
. By default, the diff view
compares the file in the merge request branch and the file in the target branch.
The diff view includes the following:
-
The file's name and path.
-
The number of lines added and deleted.
-
Buttons for the following options:
-
Toggle comments for this file; useful for inline reviews.
-
Edit the file in the merge request's branch.
-
Show full file, in case you want to look at the changes in context with the rest of the file.
-
View file at the current commit.
-
Preview the changes with
[
Review Apps
](
../../../ci/review_apps/index.md
)
.
-
The changed lines, with the specific changes highlighted.
![
Example screenshot of a source code diff
](
img/merge_request_diff_v12_2.png
)
## Commenting on any file line in merge requests
> [Introduced](https://gitlab.com/gitlab-org/gitlab-ce/issues/13950) in GitLab 11.5.
...
...
spec/features/merge_request/user_selects_branches_for_new_mr_spec.rb
View file @
9516bcd3
...
...
@@ -64,7 +64,7 @@ describe 'Merge request > User selects branches for new MR', :js do
click_button
"Check out branch"
expect
(
page
).
to
have_content
'git checkout -b
orphaned-branch origin/orphaned-branch
'
expect
(
page
).
to
have_content
'git checkout -b
"orphaned-branch" "origin/orphaned-branch"
'
end
it
'allows filtering multiple dropdowns'
do
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment