Go to TogaWare.com Home Page. GNU/Linux Desktop Survival Guide
by Graham Williams
Duck Duck Go



CLICK HERE TO VISIT THE UPDATED SURVIVAL GUIDE

Git Branch Migration

20210121 With the change of the default naming of the core branch of a repository to main (by GitHub from 1 October 2020) users can rename their default branch from master to main. The steps are to backup the current repository in case of loss, create the main branch, push it to the repository, point HEAD to the new branch, connect to GitHub or BitBucket and under Settings/Branches or Advanced select Main as the default, then delete the original branch.

$ rsync -avzh ./ ../repo_backup_`date +%Y%m%d`/
$ git branch -m master main
$ git push -u origin main
$ git symbolic-ref refs/remotes/origin/HEAD refs/remotes/origin/main

Connect to GitHUb: Settings/Branches Branches/Main as default.

$ git push origin --delete master


Support further development by purchasing the PDF version of the book.
Other online resources include the Data Science Desktop Survival Guide.
Books available on Amazon include Data Mining with Rattle and Essentials of Data Science.
Popular open source software includes rattle and wajig.
Hosted by Togaware, a pioneer of free and open source software since 1984.
Copyright © 1995-2020 Togaware Pty Ltd. Creative Commons ShareAlike V4.