inbo / checklist

An R package for checking R packages and R code
https://inbo.github.io/checklist
GNU General Public License v3.0
16 stars 2 forks source link

master vs main #44

Closed ThierryO closed 3 years ago

ThierryO commented 3 years ago

GitHub now uses main instead of master as default branch.

Currently, the checklist package requires a master branch. How should be adopt? Allow both master and main? Require main instead of master? Please add your ideas @inbo/bmk @inbo/oscibio

peterdesmet commented 3 years ago

Although I like a uniform approach, I would allow both, since it's not wrong to use master (or main). R GitHub action templates also allow both, e.g. https://github.com/r-lib/actions/tree/master/examples#when-should-you-use-it

ElsLommelen commented 3 years ago

I agree with @peterdesmet to allow both. If main is required, we cannot use checklist on existing packages (without going trough major difficulties), which is a pity, I think. It is certainly good to stimulate the use of main, but as I am not mistaken, the use is mainly determined by the default in GitHub (as the repo is setup there and not by using checklist).

Side comment: would it be a good idea to mention this change to main somewhere in an OSD newsletter? Just like me, people may not be aware why the default has changed, and change it to master just because they are habituated to this term.

damianooldoni commented 3 years ago

I vote for allowing both with informative message about the change from master to main.

ThierryO commented 3 years ago

@damianooldoni can you suggest a message?

We could turn that message into a note which you can allow. You don't get a note if you use main. You get a note if you use master. Note make the CI tests fail, unless you allow the note. Which implies motivating why you allow it. Nudging developers towards using a main branch.

ElsLommelen commented 3 years ago

@ThierryO Good idea to add it as a note, in case you explain in the note why main is preferred. I don't know if it is possible to somehow add the link there? Otherwise you could explain it shortly, and add the link in the documentation (vignette).

damianooldoni commented 3 years ago

I think the note should for sure mention this page: https://github.com/github/renaming

Here below a short as possible message:

Branch master detected. From Oct. 1, 2020, any new repositories you create uses main as the default branch, instead of master. You can rename the default branch from the web. More info on https://github.com/github/renaming