You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I wish to propose renaming the default branch from master to main. The larger developer community has been moving away from non-inclusive terms such as master, slave, blacklist, whitelist, and I wish for RubyGems & RubyGems.org to do the same.
Other examples of open source projects renaming their default branch main:
This change is relatively minimal thanks to Github natively supporting renaming the default branch to main and will do most of the work for us automatically, such as adding automatic redirects & updating existing Pull Requests to point to main. But this will require some manual steps.
As mentioned, Github automates most of the needed steps to switch the default branch to main, but some steps still need to be performed manually by maintainers before & after the rename.
The following list covers steps that to my knowledge are required to do, but may not be indicative of covering everything.
Github Actions
Before renaming the default branch in Github, the Github Action Workflows will need to be amended to mirror the main and master branches. So that we can test pushing a commit to main, while developers continue to use master.
Update branch protection rules
We currently use branch protection to prevent merging Pull Requests that do not pass the status checks. This rule will need to be updated to use main after the default branch changes.
Local Migration
After the rename, developers will need to migrate their local development environment to main. This migration can be done by renaming the master branch to main and updating the remote to origin/main
IMHO we should just copy Ruby repo standards and discuss overall renaming of all Ruby repos (including std. libs - RubyGems) at https://bugs.ruby-lang.org/.
What impacts would this change cause downstream, such as Ruby-src, Truffleruby & JRuby?
It does affect syncing with ruby-core because current scripts hardcode "master" as the default branch. They would need to be updated to infer the default branch for each repository instead of hardcoding it.
Are any scripts/tooling affected by this proposed change?
The scripts that generate the changelog will be affected, and also GitHub workflows.
Is the workflow in bundler-site affected by this proposed change?
We currently use branch protection to prevent merging Pull Requests that do not pass the status checks. This rule will need to be updated to use main after the default branch changes.
Abstract
I wish to propose renaming the default branch from
master
tomain
. The larger developer community has been moving away from non-inclusive terms such as master, slave, blacklist, whitelist, and I wish for RubyGems & RubyGems.org to do the same.Other examples of open source projects renaming their default branch main:
master
tomain
rails/rails#40214This change is relatively minimal thanks to Github natively supporting renaming the default branch to
main
and will do most of the work for us automatically, such as adding automatic redirects & updating existing Pull Requests to point tomain
. But this will require some manual steps.You can find more information at: https://github.com/github/renaming.
Steps Required
As mentioned, Github automates most of the needed steps to switch the default branch to
main
, but some steps still need to be performed manually by maintainers before & after the rename.The following list covers steps that to my knowledge are required to do, but may not be indicative of covering everything.
Github Actions
Before renaming the default branch in Github, the Github Action Workflows will need to be amended to mirror the
main
andmaster
branches. So that we can test pushing a commit tomain
, while developers continue to usemaster
.Update branch protection rules
We currently use branch protection to prevent merging Pull Requests that do not pass the status checks. This rule will need to be updated to use
main
after the default branch changes.Local Migration
After the rename, developers will need to migrate their local development environment to
main
. This migration can be done by renaming themaster
branch tomain
and updating the remote toorigin/main
Remove/Rename references to master branch
Update Github actions to remove any branch filtering on the
master
branch and rename any references tomaster
in the documentation & source code.Renaming the default branch
The default branch can be renamed in Github, which is documented in doc.github.com
Questions
What impacts would this change cause downstream, such as Ruby-src, Truffleruby & JRuby?
Are any scripts/tooling affected by this proposed change?
Is the workflow in bundler-site affected by this proposed change?
The text was updated successfully, but these errors were encountered: