Derrick Stolee <stolee@xxxxxxxxx> writes: > On 6/11/2020 7:59 AM, Don Goodman-Wilson wrote: >> On Thu, Jun 11, 2020 at 1:52 PM Michal Suchánek <msuchanek@xxxxxxx> wrote: >>> Indeed, the flexibility to choose the name of the default branch can be >>> helpful for projects with specific naming, especially non-english >>> speaking projects. >>> >>> To that end I would suggest adding -b argument to git init to be able to >>> choose the default branch name per project. This should select the >>> initial branch name and also write the it as the default branch name in >>> the repo configuration (if git continues to treat the default branch >>> specially). >>> >>> This can be used in documentation to use the new name immediately >>> without breaking existing workflows that rely on the 'master' branch. >> >> I _really_ like this idea (and your reasoning). Seconded. > > Yes, adding a -b|--branch option would be an excellent addition to > the config option. In the ideal world, users should be able to just set init.defaultBranchName in ~/.gitconfig once and forget about it. But it is expected that some projects and their tools may heavily depend on the assumption that the primary branch is called 'master'. Giving a command line override like "init -b" (and do not forget to do the same for "clone" as necessary) is a good escape hatch for members of such projects. Good.