FS#72163 - Support branches called "main" as well as "master"

Attached to Project: AUR web interface
Opened by Patrick Reader (pxeger) - Friday, 17 September 2021, 17:02 GMT
Last edited by Jonas Witschel (diabonas) - Wednesday, 10 November 2021, 18:10 GMT
Task Type Feature Request
Category Backend
Status Closed
Assigned To No-one
Architecture All
Severity Low
Priority Normal
Reported Version 4.7.0
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Some users are choosing to call the primary branch of their repositories "main" rather than "master. PLEASE DO NOT ARGUE ABOUT THE REPLACEMENT OF THE NAME MASTER WITH MAIN. We are all tired of hearing about this.

The fact remains that some users are using "main" as their default branch name[*]. The AUR currently rejects pushes to any branch that is not called "master". I've found it a (very mild) pain to have to rename the branch, but there may be some users who are more annoyed by having to use the name "master". (again, PLEASE DO NOT ARGUE about whether the name "master" is inappropriate - that is off-topic). So it would be a nice-to-have to permit "main" as well as "master" as a branch name. It's probably sensible to allow only one or the other, although this might prove complicated to implement.

[*] especially as git now prints that message `git init`:

hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: git branch -m <name>
This task depends upon

Closed by  Jonas Witschel (diabonas)
Wednesday, 10 November 2021, 18:10 GMT
Reason for closing:  Duplicate
Additional comments about closing:   FS#72257 

Loading...