Steps to reproduce:
- Open the Unity Hub
- Click the "New project" button
- Set Source control provider to GitHub
- Connect Personal Access Token
- Create project
- Exit the Editor
- Open the foldout of the created project in the Hub
- Click the "Disconnect from GitHub" button
- Click the "Connect to source control" button
- Open the Additional configuration foldout
- Change the Default branch name to "asddd"
- Click the "Connect" button
- Observe the branch name
Actual results: In both Hub and GitHub the branch name is "main"
Expected results: In both Hub and GitHub the branch name is "asddd"
Reproducible with versions: 3.17.2
Tested on (OS): MacOS Silicon Tahoe 26.3
Notes:
- Changing default branch name works properly when creating a project, the issue is when the project was already connected to a repository but was disconnected and connected to a new repository
- If the project is created with a different branch name, in the reproduction instead of "main" the branch will fallback/reset to whatever the name was used when the project was created