Rename "master" branch to "main" for glibc 2.35 release.

H.J. Lu hjl.tools@gmail.com
Mon Jan 31 18:14:31 GMT 2022


On Mon, Jan 31, 2022 at 10:09 AM Adhemerval Zanella via Libc-alpha
<libc-alpha@sourceware.org> wrote:
>
>
>
> On 29/01/2022 19:32, Carlos O'Donell via Libc-alpha wrote:
> > In June 2020 I started this thread for glibc 2.32:
> > https://sourceware.org/pipermail/libc-alpha/2020-June/115579.html
> > to discuss a branch name change.
> >
> > Thanks to Paul, Florian, Joseph and DJ who provided feedback on
> > the initial discussion.
> >
> > As of today the default Gitlab new branch is "main" (Gitlab 14 or later).
> >
> > As of today the default Github new branch is "main".
> >
> > With Git 2.28+ the default branch name is configurable.
> >
> > Git has added this advisory text:
> > ~~~
> >  562 static const char default_branch_name_advice[] = N_(
> >  563 "Using '%s' as the name for the initial branch. This default branch name\n"
> >  564 "is subject to change. To configure the initial branch name to use in all\n"
> >  565 "of your new repositories, which will suppress this warning, call:\n"
> >  566 "\n"
> >  567 "\tgit config --global init.defaultBranch <name>\n"
> >  568 "\n"
> >  569 "Names commonly chosen instead of 'master' are 'main', 'trunk' and\n"
> >  570 "'development'. The just-created branch can be renamed via this command:\n"
> >  571 "\n"
> >  572 "\tgit branch -m <name>\n"
> > ~~~
> >
> > My proposal is to rename the development and release branches at the point
> > that glibc 2.35 branches:
> >
> > * master -> main
> >
> > * release/2.35/master -> release/2.35/main
> >
> > No alias would be provided for the master branch; we would immediately
> > start using 'main' as the development branch.
> >
> > I am looking for consensus on this proposal.
> >
> > Details:
> > ========
> >
> > Given the feedback from the last proposal I have done the required
> > review to ensure the transition can happen smoothly within our own
> > infrastructure.
> >
> > This proposal is only about the development branch and upcoming release
> > branch. All historical branches remain at their existing names.
> >
> > I have reviewed the git hooks, and we would need to make changes to the
> > following files after the transition:
> > * hooks-bin/email-to-bugzilla-filtered
> > * hooks-bin/post-receive
> >
> > Our hooks implementation (AdaCore's hooks) is neutral on the branch name
> > used. There are two instances where 'master' is removed for '' to
> > shorten an email message because it's the "default", but that should not
> > be a blocker for our transition.
> >
> > There are changes required to our project.config in refs/meta/config:
> > * reject-merge-commits for 'main' needs to be set.
> > * allow-non-fast-forward must be adjusted for 'main'.
> >
> > Wiki pages that need changing immediately:
> > * https://sourceware.org/glibc/wiki/GlibcGit
> >
> > How to update a renamed upstream branch:
> > # Rename old branch to new branch.
> > $ git branch -m OLD-BRANCH-NAME NEW-BRANCH-NAME
> > # Fetch upstream origin to get new branch name.
> > $ git fetch origin
> > # Set upstream to thew new renamed branch.
> > $ git branch -u origin/NEW-BRANCH-NAME NEW-BRANCH-NAME
> > # Set the default branch for origin automatically
> > $ git remote set-head origin -a
> > # Prune the old references away.
> > $ git remote prune origin
> >
> > Website needs updating immediately:
> > * https://www.gnu.org/software/libc/sources.html
> > * https://www.gnu.org/software/libc/started.html
> >
> > All other wiki, web, and source references can be adjusted over time.
> >
>
> I must say that I am failing to see any technical advantage or improvement
> of doing this change.

Same here.  If we do want to change, I think "dev" is better than "main".
"dev" indicates that the branch is under development.

-- 
H.J.


More information about the Libc-alpha mailing list