Skip to content

Move the default branch from master to main #313

Closed

Description

@mauroservienti

Move the default branch from master to main, consistent with the other repositories.

Rename the branch

In Settings > General > Default branch, rename master to main, or run:

gh api -X POST repos/RadicalFx/documentation/branches/master/rename -f new_name=main

GitHub updates branch protection rules and the base of open pull requests, and redirects web URLs that point to master. It doesn't update workflow branch filters, file contents, or raw URLs (raw.githubusercontent.com), so those are listed below.

Files that still say master

  • .github/workflows/ci.yml:7: push branch filter. Change it to main in the same pull request that follows the rename (or right before), otherwise pushes to main won't run CI.
  • docs/README.md:64: contribution guide says to branch off master.
  • tree/master/samples links (they redirect, but should point to main):
    • docs/README.md:88
    • docs/ioc/third-party.md:46
    • docs/samples.md: line 3 and every sample link in the tables (lines 11 to 63)
    • docs/ui-composition/index.md:5
    • docs/upgrade-guides/1.x-to-2.0.0.md:52
  • Optional: the release-1, release-2 and release-3 branches may contain the same links. Harmless, since they redirect.

Check CI

  • After the rename and the filter change, a push to main runs CI as before.

Check GitBook

  • After the rename configure GitBook to sync from main instead of master

Update local clones

git branch -m master main
git fetch origin
git branch -u origin/main main
git remote set-head origin -a

Activity

  1. mauroservienti commented on Nov 11, 2026

    @mauroservienti
    MemberAuthor

    Done: the default branch is main. #318 updated the CI push filter and the repository links, CI runs on pushes to main, and GitBook syncs from main. The tree/master links in the release-* branches are left as they are, since they redirect.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions