Changes

Jump to: navigation, search

GitHub/Changing Default Branch

No change in size, 04:15, 20 January 2021
m
fix typo
There are many good reasons to rename the default branch for your repository. GitHub gives some of the reasons and [https://github.com/github/renaming/ provides guidance] for the procedure.
However, if your repository has been in use for a while, everyone who has clones of the repository much must update their clones to properly reflect the change. GitHub will add messages to the output of git commands to inform folks, but it is very easy to miss those. If the per-clone changes are not made, then the branch could accidentally be re-created with old contents. The procedure below provides a workaround, which can be enabled by a repository admin.
1. Rename the default branch, following [https://github.com/github/renaming/#renaming-existing-branches GitHub's instructions].
Confirm
1,197
edits

Navigation menu