change master branch to main github code example Example: change master to main git $ git branch -m master main