how to change the name of the master to main code example Example: git rename master to main $ git branch -m master main