-
Notifications
You must be signed in to change notification settings - Fork 47.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The primary branch has been renamed from "master" to "main" #21767
Comments
In case it is helpful for others, ere is a list of steps I have taken for this transition:
|
Need to follow up on why d483463 triggered a failed deployment of the scheduling profiler: Not sure why this would fail, as Vercel is configured to support either
Re-ran again and it passed: |
Note that, unfortunately, it seems like existing PRs might be broken by this change after all– until they rebase on Ideally we would have auto-detected the primary branch in these scripts (e.g. For now, I've added a section to the issue above with the Circle CI task that fails and how to fix it (by rebasing). Edit: Looks like this is working okay for pre-existing PRs, e.g. #21766 |
We can probably close this now. |
Renaming
master
branch tomain
As a part of a broad effort to avoid problematic terminology in our software, we are renaming our default branch from
master
tomain
. We recognize that this is only a small step, but it is an opportunity to make our project and community more welcoming to historically marginalized communities.How does this impact my development process?
There should be very little impact. GitHub will surface the branch name change in your fork, if you have one. For new forks, you will automatically have
main
as the default branch.We encourage the use of feature branches for local development. The only change in practice is changing which branch your feature branch is started from. When sending Pull Requests on GitHub, the target will default to our
main
branch, so there are no changes to make there.I have a lot of tools that depend on
master
being the upstream branch name. How can I fix that?master
has always been only a default value and a number of projects have used other names for their primary development branch for years. We encourage updating your tooling to instead dynamically determine the branch to use. This article provides insight into how you can do that. Additionally, you can always set up a branch locally of any name to track ourmain
branch.I'd like to do this for my own projects, do you have any documentation on how this works?
GitHub has published a guide documenting their tooling. We recommend reading that and the accompanying documentation.
If you're a Facebook employee looking to do this for a project you maintain, please reach out to the Open Source Team.
My PR is failing because of
ci/circleci: get_base_build
This is because the
master
branch has been renamed tomain
, but our Circle CI scripts used to refer tomaster
by name. To fix this, just rebase your branch on top ofmain
to get the latest version of the Circle CI scripts:The text was updated successfully, but these errors were encountered: