Social: A Small Step to Address Poor Past Behavior

Tl;Dr – This is about changing your main branch in git to main. However, please read and think about what I am saying here.

When I started working with Version Control, the main branch was named trunk. I worked with code and we always branched away from trunk, which was our source of truth. I have no idea of the origin, though people seem to think this relates to trees. That makes sense.

Then why master? No idea. The inventor of Git is Linus Torvalds. He’s been accused of poor behavior, though I don’t know I think he is racist. Git was supposedly chosen as it’s an unpleasant person in British slang. That makes sense.

I followed him early on, and remember trying to get Linux 0.6 working on hardware. I was fascinated with his work, and I hope he chose “master” as the moniker for the main branch because of the verb definition rather than the noun. Who knows?

In any case, technology is littered with the use of “master” in our terminology. Replication, especially, but HA tech and in many places where we distribute something from one machine to another. I would like to think this is idea of one with more/better knowledge (the master, in the Kung Fu sense), distributing that to others.

However, there is the connotation of control.

The IETF agrees and has draft terminology change recommendations. In line with that, I saw a note from Scott Hanselman on changing your git default branch, this after I saw a few people this weekend noting they were submitting PRs to make the change.

I decided to do the same. I don’t know how to do this on GitHub without a local repo, so I’m following Scott’s process.

git branch –m master main
git push –u origin main

This moves all the code (all commits and history) to a branch called main. Then pushes this up and tracks it.

Once it’s there, I need to go to the repo settings and change the default branch to main and delete master. This will cause some issues on laptops, but those are up to date, or they have minor unpushed demo changes that I can abandon. I’ll then pull down the new structure of the repo.

Don’t do this haphazardly. Communicate with your team and ensure everyone is aware of the change. Then slowly work your way through the repos. It’s a chore but a small one. One I’ll be working my way through until I’m done.

About way0utwest

Editor, SQLServerCentral
This entry was posted in Blog and tagged , , . Bookmark the permalink.

3 Responses to Social: A Small Step to Address Poor Past Behavior

  1. tony says:

    I think people rushing to do this is an overreaction to current events. Master has many definitions, and I dont’ believe that master in this context means anything other than “an original recording, film, or document from which copies can be made.”
    This feels like deciding to be ofended by something that never was offensive.

    Liked by 1 person

    • way0utwest says:

      You can think whatever you want. To me, this is a tiny change I can make, and will.

      Like

    • Tony, You are %100 correct. The IETF alternatives are acceptable for now but you can bet that will change. The line will be moved again and after Master/Slave has been purged from the terminology the IETF alternative of Primary will be targeted next as “problematic”. Primary implies that one thing comes before another, is above or superior to another and that is a problem. Its acceptable now only because Master/Slave is more problematic. This sounds ludicrous now but what is now being accepted as normal was seen as ludicrous just a few years earlier. As long as language can be controlled, the use of vocabulary restricted because some group is offended, we are all in trouble. As long as the masses continue to appease the mob the line will continue to move. This is the nature of mob rule, you can never appease the mob only temporarily appease it.

      Like

Comments are closed.