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