Thread (21 messages) flat view 21 messages, 7 authors, 2016-06-15

Re: Pull is Mostly Evil

From: David Kastrup <hidden>
Date: 2016-06-15 23:00:59

Jeff King [off-list ref] writes:
On Fri, May 02, 2014 at 02:11:05PM -0500, Felipe Contreras wrote:
quoted
Junio C Hamano wrote:
quoted
If we step back a bit, because we are forcing him to differentiate
these two pulls in his mental model anyway, perhaps it may help
people (both new and old) if we had a new command to make the
distinction stand out more.  What if the command sequence were like
this instead?

    $ git checkout maint
    $ git update [ origin maint ]

    $ git pull [--no-ff] developer-remote topic-branch
    $ git push [ origin maint ]

where the new command 'update' enforces the '--ff-only' update.  And
then we would stop telling "'git pull' first" when a push does not
fast-forward.
In addition to barf when it's not a fast-forward, such command can
switch the parents, so it appears 'maint' was merged to 'origin/maint'.
Many people have complained about this order.
I realize this has veered off into talking about an "update" command,
and not necessarily "pull", but since there a lot of proposals floating
around, I wanted to make one point: if we are going to do such a switch,
let's please make it something the user explicitly turns on.
A safety catch defaulting to a factory position of "off" is not going to
stop inexperienced people from shooting themselves in the foot.

-- 
David Kastrup
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help