[go: up one dir, main page]

Skip to content

Change default target branch to the private project one when creating from a private project.

Everyone can contribute. Help move this issue forward while earning points, leveling up and collecting rewards.

Context

When visiting a branch in a private repository that is a fork of another project and using the "Create merge request" button, the default target branch is the public repository. While there is a warning that highlights it targets the public repository:

Screenshot_from_2024-07-15_15-29-53

This can be overlooked easily.

Steps to reproduce

  1. Fork a public project into a private repository
  2. Create a new branch and make some changes
  3. Go to the Web UI on the branch you created
  4. Click "Create a merge request"
  5. Observe it targets the public repository branch by default

Proposed change

It would be great if the default was to target the main branch of the private repository, with the option to change it to the public one as needed. This would be a more secure-by-default design.

Edited by 🤖 GitLab Bot 🤖