~~New repository should start using `main` as the default branch, fall back to `master` when `main` is not available when the default branch is not set.~~ When detecting the default branch, try `main` if `master` is not available.