Answers for "git switch main branch"

0

How to switch from master to main git branch

git checkout master        # to be sure you are on master branch
git push origin HEAD:main  # and then push the current branch (as master) to main
-or-
git push --force origin HEAD:main
Posted by: Guest on June-09-2021
3

git switch branch

git switch branch_name

git checkout branch_name
Posted by: Guest on March-20-2020
1

how to make new branch and switch in git

git checkout -b myNewBranch
Posted by: Guest on April-25-2021
1

git switch branch

wonder.woman@highfive project %  git checkout branch_name 
#this let you keep edited files
wonder.woman@highfive project %  git switch branch_name
Posted by: Guest on March-20-2020
0

git toggle between branches

Toggle between two git branches: git checkout -
Posted by: Guest on November-03-2020

Code answers related to "git switch main branch"

Browse Popular Code Answers by Language