-
Angelina Elizabeth Uno-Antonison authored50f8e5a4
merge-requests.md 4.26 KiB
Merge Requests
Merge requests allow team members to visualize and collaborate on the proposed changes to work that exist as commits on
a given Git branch. At CGDS, merge requests are feature-based
, meaning when the work for a proposed topic is complete,
the proposed changes are requested to be reviewed and integrated into the origin/master
branch.
The procedures for drafting, reviewing, and merging Merge Requests
are listed below. Visit
GitLab Add Merge Request to learn how to execute a
GitLab merge request.
Creating Merge Request
- Navigate to
Branches
section of theProject
within GitLab that needs to be merged. - Initiate the merge request by pressing the
Merge request
button that is on the row of the desired branch to merge. - Enter a descriptive title according to the work being reviewed. Afterwards, set the merge request to be a
Work inProgress
AKAWIP
. - Write a complete summary of the changes that are included in the Merge Request in the
Description
text area. - Select an
Assignee
in the drop down menu to assign who will review the merge request.- The assignee chosen is up to the discretion of the user creating the merge request. The assignee is either the person who is accountable for the project or the content is within their area of expertise.
- If the chosen assignee is someone who neither has expertise using Gitlab's advanced features nor will be working frequently with such features in future (e.g. analysts), the MR submitter will converse with the assignee outside of Gitlab, get their comments, resolve the conflicts, get the changes approved by assignee, document assignee's comments in gitlab, and then will finalize the MR themselves.
- Select the
Target branch
that the work is being pulled into. This is not alwaysorigin/master
. - Check the
Delete source branch when merge request is accepted
checkbox.- It is optional to select
Squash Commits
. If there were commits that will benefit from having the history then it is recommended to not squash.
- It is optional to select
- Click the
Submit merge request
button at the bottom left of the merge request.
Reviewing Merge Request
This will be performed by the assignee (aka reviewer).
- Assigned reviewers will review the proposed changes via
Merge Request
view in GitLab. They will leave comments and request changes as needed.- Read GitLab Resolvable Comments and Threads to learn more about creating comments and suggestions within a merge request.
- The user who submitted the merge request must respond to all comments and suggestions.
- Once the reviewer is satisfied with responses and suggested changes, they will
Resolve
the threads.- Read GitLab Marking Comments and Threads Resolved to learn more about resolving threads.
- GitLab will not allow the branch to be merged until all comments and threads are resolved.
- If there is a disagreement between the author of the proposed changes and reviewer, a third party team member can be brought in to help determine a solution.
- The final reviewer will remove the
Work in Progress
status once they are a satisfied with responses to comments and the resolutions in regards to changes requested. There are two ways to remove tehWIP
status: