Wrong Default Branch Selected Locally
See original GitHub issueDescription
using only GitHub Desktop i created a branch named sfdx-master
from master
one. there i re-structured APEX files to comply with file structure requirements of SFDX way of packaging. that was experimental branch so i switched back to master
then and tried to create another branch (i.e. feature-x
), but GitHub Desktop showed me branch i had to create the new one from as sfdx-master
, not master
.
i thought it was a glitch, but i can reproduce that on that local copy again and again.
to solve the weird default branch issue i got to our GitLab repo, but the default branch there is still master
despite i pushed to there and fetched updates from there.
in GitHub Desktop itself i do not see a setting to choose a default branch. afaik, gif also does not have the “default branch” concept. so i have no idea on how to set master
as the default branch back.
Version
- GitHub Desktop: 1.5.1
- Operating system: Microsoft Windows [Version 10.0.17134.472]
Steps to Reproduce
- switch to master
- menu Branch > New Branch
- look at “Create branch based on…” selector
Expected Behavior
default branch is master
Actual Behavior
default branch is sfdx-master
Additional Information
Logs
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (4 by maintainers)
Top GitHub Comments
@hlopetz it might have been that the clone existed before the rename was applied, and in typical Git
fetch/push/pull
usage the rename of the default branch wasn’t updated?Anyway, I’m glad we got to the bottom of the issue. I’m going to close this out as resolved, but let us know if you have any other questions about this.
thank you @shiftkey,
git remote set-head origin master
worked for me. the only Q is how that could happen if i used GitHub Desktop app only.