Junio C Hamano wrote: > Felipe Contreras <felipe.contreras@xxxxxxxxx> writes: > > >> I suspect it would be simpler to read and easier to understand to > >> bring the parethesized part front, e.g. > >> > >> If you are pushing to the same repository you pull from (which > >> is typically `origin`), then you need to ... > >> > >> as it would avoid "the project is not centralized, but I push to my > >> own repository and pull from it---what should I do?" questions. > > > > The top of `push.default says: > > > > Different values are well-suited for specific workflows; for instance, > > in a purely central workflow (i.e. the fetch source is equal to the > > push destination), `upstream` is probably what you want. > > > > We already brought up the central workflow, I think it's fine to reuse > > the concept below. > > Oh, thanks for finding another instance to be corrected. In fact there's many: This mode only makes sense if you are pushing to the same repository you would normally pull from (i.e. central workflow). > Even in that sentence, the more important point is that upstream would > be appropriate if you push to the same place as you fetch from, and we > do not have to say "purely central" at all. Actually, I forgot the main reason I decided to rename centralized to same_repo: they are not the same thing. You can have a decentralized workflow where you have multiple repositories configured, but every branch pulls and pushes to the same repository (to them, not other branches): hotfix <-> dayjob/production cleanups <-> upstream/master experiment-1 <-> personal/experiment-1 So it's more like: centralized = ~decentralized triangular = ~two-way A centralized workflow consists of a single repository where branches are typically two-way, but not necessarily. A decentralized workflow consists of multiple repositories where branches are typically triangular, but not necessarily. So the triangularity is per branch, not per repository, and same_repo means a two-way branch, could be a centralized or decentralized workflow. Therefore your proposal: If you are pushing to the same repository you pull from (which is typically `origin`), then you need to ... is actually better, I just had to remind myself that centralized and same repo are not the same thing. Of course it would help to have a place in Documentation/ where trianguar and centralized are explained. Cheers. -- Felipe Contreras