Re: Dropping '+' from fetch = +refs/heads/*:refs/remotes/origin/*?

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Re: Dropping '+' from fetch = +refs/heads/*:refs/remotes/origin/*?

From: Matthieu Moy <hidden>
Date: 2016-06-15 22:51:57

Michael J Gruber [off-list ref] writes:
Thinking more about it, we try to encourage a workflow where locally
history may be rewritten a lot, and distribution points fast-forward
only. We have defaults and settings to discourage (pushes to checked out
branches and) non-ff pushes, for example. So I think the above change is
pretty much in line with that reasoning.
Agreed. It's not only a security thing, it's also about
teaching/encourraging workflows.

By asking users to explicitely say "yes, I know, this branch can be
rewond", we also ask them to think about it before making a mistake.

That said, enabling the check by default may also become painful. I'd
vote for a configuration option, defaulting to the current behavior for
now. Then we can try living with it for a while and see how painful it
is.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/

Re: Dropping '+' from fetch = +refs/heads/*:refs/remotes/origin/*?

From: Shawn Pearce <hidden>
Date: 2016-06-15 22:51:58

On Thu, Sep 1, 2011 at 12:35, Matthieu Moy [off-list ref] wrote:
By asking users to explicitely say "yes, I know, this branch can be
rewond", we also ask them to think about it before making a mistake.

That said, enabling the check by default may also become painful. I'd
vote for a configuration option, defaulting to the current behavior for
now. Then we can try living with it for a while and see how painful it
is.
I suspect the vast majority of branches in the wild do not rewind
under normal conditions. Users who work against branches that rewind
(e.g. those of us basing on a topic in pu) are already sophisticated
enough with Git to understand what the fetch error would mean and fix
it.

IMHO, just change the default in clone, and better, add a warning to
fetch if that default pattern is still in the configuration file. Let
the user either remove the wildcarded force fetch spec, or add a new
configuration variable to his remote block to silence the warning.

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