An error occurred while fetching the assigned milestone of the selected merge_request.
[WIP] Add option to create merge request when editing/creating a file
Fixes #3059 (closed). This PR adds an option to create a merge request directly after creating/updating a file ("blob"). If the user changes the name of the branch, a new option is shown.
One thing in particular remains to be done:
-
On the new MR, target branch should be set to the branch the user was originally on instead of using always 'master'.
A few improvements that could be done (maybe in separate issues):
-
Reduce code duplication in the blobs views. -
Add controller tests for creating/editing blobs. -
Add service tests for Files::CreateService.
Merge request reports
Activity
Added 1 commit:
- 3d50b99d - Add option to create merge request when editing/creating a file
27 27 if result[:status] == :success 28 28 flash[:notice] = "The changes have been successfully committed" 29 29 respond_to do |format| 30 format.html { redirect_to namespace_project_blob_path(@project.namespace, @project, File.join(@target_branch, @file_path)) } 30 format.html do 31 url = if params[:create_merge_request] 32 new_mr_path_from_push_event(current_user.recent_push(@project.id), @ref) mentioned in merge request !1820 (merged)
@dirceu Thanks again for your work! I created !1820 (merged) based on this MR with a little bit of added functionality.
mentioned in commit 3a85c93a
mentioned in commit 463a3cfe
Please register or sign in to reply