Created
July 1, 2020 10:59
-
-
Save andrzejkaszkowiak/eb40f135a76fb37f0dae3dea93a28639 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# https://www.hanselman.com/blog/EasilyRenameYourGitDefaultBranchFromMasterToMain.aspx | |
# git branch -m master main | |
# git push -u origin main | |
git checkout master | |
git branch -m master main | |
git fetch | |
git branch --unset-upstream | |
git branch -u origin/main | |
git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/main |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment