Re: [RFC PATCH 0/4] deny push to current branch of non-bare repo

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Leo Razoumov <slonik.az@...>
Cc: Junio C Hamano <gitster@...>, <git@...>, Sam Vilain <sam@...>
Date: Monday, December 1, 2008 - 10:48 pm

On Mon, Dec 01, 2008 at 09:22:43PM -0500, Leo Razoumov wrote:


  a) you are responding to a nearly month-old message. Please read the
     rest of the thread where we decide that it is not so insane, and
     that the behavior should be configurable with a default of "warn"
     at least for now.

  b) My comment was not that it is insane simply because it is different
     from mine. It is because it creates a dangerous situation (where
     dangerous implies changes might be silently lost) which requires
     manual intervention to fix, and which the user was given no warning
     whatsoever about. It is a direct response to frequent complaints on
     the list about users getting bit by this.


(3) Use git-reset --hard, but set a config variable that says "I know
what I'm doing." You don't even have to do it per-repo, you can do it
per-user.

(4) Push into a non-current branch and merge from the target.


Er, what? git-fetch takes a refspec very similar to the ones used by
git-push. The real reason that (2) is not an acceptable solution is that
you can't necessarily connect to the source repo (e.g., it is on your
workstation with no ssh or git server running).

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [RFC PATCH 0/4] deny push to current branch of non-bare ..., Jeff King, (Mon Dec 1, 10:48 pm)
Re: [RFC PATCH 0/4] deny push to current branch of non-bare ..., Johannes Schindelin, (Sat Nov 8, 11:12 am)
[PATCH 2/4] t5516: refactor oddball tests, Jeff King, (Fri Nov 7, 6:20 pm)