When working with text files such as source code, the “copy-modify-merge” workflow method is preferable to the “lock-modify-unlock” method because it allows for two developers to work on the same file simultaneously as long as their edits do not conflict each other.
In Assembla Subversion repositories, you can review changes made in branches and merge them back into the trunk (or any SVN directory) using a merge request.
NOTE: It is important to remember that the branch/merge method does not work with unmergeable files like binary files. For binary files, the recommended method to avoid conflicts in changes is to use file locks.
How do I add a new merge request in my SVN repository?
To add a new merge request, simply go to the Merge Requests sub-tab of your desired SVN repository. Then, select the New Merge Request button to the right of the screen.
From there, the source branch can be selected from the From dropdown menu. The target branch can also be selected under To. The green circle between the From and To sections can be used to reverse the selections.
A title for the merge request will be automatically generated from the title of the first commit on that branch. You can change the title before proceeding. It is generally best practice limit merge request titles to under 100 characters and make them as descriptive as possible for easy reference later.
Additionally, in the description for the merge request, tickets can be referenced with the same syntax used to reference tickets in commits (re #ticket_number).
PRO TIP: If you had already associated any tickets with commits that will included in the merge request, they will automatically be associated with the respective merge request!
If you would like to delete the source branch after the merge request is either merged or ignored, simply check the box under the merge request's title.
The commits and affected files on the source branch will be shown at the bottom of the screen and the Affected tickets section on the right of the screen will show all of the tickets referenced in the commits to that branch.
Once the target and source branches have been chosen, select Create Merge Request to finish creating your request.
From there, you can request teammates to review your changes, communicate about any changes that need to be made, and ultimately merge you work once your team approves!
Merge Request Options
Once your MR is created you can find it in the Merge Requests sub-tab. To access it just click on it. In your MR page, you’ll see some options:
Upvote or downvote a MR: After each revision you can upvote a MR or downvote it.
Merge and Close button: If everything is OK you can merge the changes and close the request with one button:
Ignore button: If a MR was created by accident or if it’s irrelevant you ignore it.
New version: If there is a new commit on the branch, a new version of the MR will automatically be created.
You can add inline comments by clicking on the green icon on each line of code. To see the files you just need to go to the “Files Affected” tab, and click on the “view diff” link.
Inline Comments can be found in a few places:
a) Affected files where it was submitted
b) Comments sub-tab - which can be enabled from the Git Tool Settings page
- The inline comments have a direct link which will redirect you to the affected file and it will open the inline comment automatically.
- Each inline comment has a reply button where you can easily respond to someone - it will send a mention to that person.
Mark Comments Resolved: Once you have pushed the changes requested by a reviewer, simply click the comment in the merge request interface to mark it "resolved." This provides a handy indicator of the status of the changes implicated by their comment.
See also Assembla Merge Requests.
Have questions? Email us at firstname.lastname@example.org