Changing Your Default Git Branch

June 15, 2020

There's been talk of changing a Git repo's default branch, currently called "master."

You may say to yourself, "What a load of horse poo!" Or "I'll have to update my scripts/CI pipeline and that will take some man hours to do."

Fair.

But then if you are ready to change over, you may be wondering...

  • What name do we choose for our new default branch? Main? Latest? Primary?
  • What eldritch recipe or complex list of steps must we follow to do this?
  • Will our project break?

Look, Scott Hanselman has you covered. It's maybe 30 seconds of work per repo.


Profile picture

Written by Shawn Borton
Drupal and PHP expert, Christian, rabid Dallas Stars fan, devoted Texas Longhorns alum, lover of libraries, coffee shops, and quiet places.
Socials: Twitter, Mastodon