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
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
a67f3c39
Commit
a67f3c39
authored
Jan 10, 2014
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'need-merge-commit' of /home/git/repositories/gitlab/gitlabhq
parents
54bcbba5
f46620e6
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
12 deletions
+12
-12
app/views/projects/merge_requests/show/_how_to_merge.html.haml
...iews/projects/merge_requests/show/_how_to_merge.html.haml
+12
-12
No files found.
app/views/projects/merge_requests/show/_how_to_merge.html.haml
View file @
a67f3c39
...
...
@@ -10,34 +10,34 @@
-
target_remote
=
@merge_request
.
target_project
.
namespace
.
nil?
?
"target"
:
@merge_request
.
target_project
.
namespace
.
path
%p
%strong
Step 1.
Checkout target branch and get recent objects from GitLab
Assuming remote for
#{
@merge_request
.
target_project
.
path_with_namespace
}
is called
#{
target_remote
}
remote for
#{
@merge_request
.
source_project_path
}
is called
#{
source_remote
}
Checkout the branch we are going to merge and pull in the code
%pre
.dark
:preserve
git checkout
#{
target_remote
}
#{
@merge_request
.
target_branch
}
git
fetch
#{
source_remote
}
git checkout
-b
#{
@merge_request
.
source_project_path
}
-
#{
@merge_request
.
source_branch
}
#{
@merge_request
.
target_branch
}
git
pull
#{
@merge_request
.
source_project
.
http_url_to_repo
}
#{
@merge_request
.
source_branch
}
%p
%strong
Step 2.
Merge
source branch into target branch and push
changes to GitLab
Merge
the branch and push the
changes to GitLab
%pre
.dark
:preserve
git merge
#{
source_remote
}
/
#{
@merge_request
.
source_branch
}
git push
#{
target_remote
}
#{
@merge_request
.
target_branch
}
git checkout
#{
@merge_request
.
target_branch
}
git merge --no-ff
#{
@merge_request
.
source_project_path
}
-
#{
@merge_request
.
source_branch
}
git push origin
#{
@merge_request
.
target_branch
}
-
else
%p
%strong
Step 1.
Checkout target branch and get recent objects from GitLab
Update the repo and checkout the branch we are going to merge
%pre
.dark
:preserve
git checkout
#{
@merge_request
.
target_branch
}
git fetch origin
git checkout -b
#{
@merge_request
.
source_branch
}
origin/
#{
@merge_request
.
source_branch
}
%p
%strong
Step 2.
Merge
source branch into target branch and push
changes to GitLab
Merge
the branch and push the
changes to GitLab
%pre
.dark
:preserve
git merge origin/
#{
@merge_request
.
source_branch
}
git checkout
#{
@merge_request
.
target_branch
}
git merge --no-ff
#{
@merge_request
.
source_branch
}
git push origin
#{
@merge_request
.
target_branch
}
...
...
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