- Notifications
You must be signed in to change notification settings - Fork913
Add implementation for git_remote_default_branch#1969
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:master
Are you sure you want to change the base?
Uh oh!
There was an error while loading.Please reload this page.
Conversation
ghost commentedJul 19, 2022
Hi@mburtka , May I suggest you to have a look at the similar functionality implemented in our fork and consider adopting (part of) it? The difference is I believe that we've exposed the GetRemoteDefaultBranch as a static method on Repository class, so that the user could get a default branch name before they clone a repo. |
atiq-cs commentedDec 17, 2022
Is there any update on this? Would love to set a default branch while initializing an empty repository. Thanks. |
Athari commentedAug 27, 2025
Any chance of getting this merged? It's still a simple change with no conflicts, so can be done at any point. |
Uh oh!
There was an error while loading.Please reload this page.
Implements the feature requested in#1796
This fetches the default branch from a remote repository. This is useful to detect changes, and when remotes are added following initialization.