pub fn get_main_branch_name(repo: &Repo) -> Result<String>
Expand description

Get the configured name of the main branch.

The following config values are resolved, in order. The first valid value is returned.

  • branchless.core.mainBranch
  • (deprecated) branchless.mainBranch
  • init.defaultBranch
  • finally, default to “master”