Re: [PATCH v3 23/23] checkout: retire --ignore-other-worktrees in favor of --force
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jul 7, 2015, 16:20 UTC
- Message-ID
- <xmqqio9w3poi.fsf@gitster.dls.corp.google.com>
- In-Reply-To
- <CAPig+cSz3xS-pdtsiw14A80m7UqdwfGLy6kRdguHSUyAjfnWSQ@mail.gmail.com>
Eric Sunshine <sunshine@sunshineco.com> writes:
Show 6 quoted lines
> Is receive.denyCurrentBranch worth mentioning as an argument? Although > pushing a branch into a non-bare repo where that branch is already > checked out is normally disallowed, receive.denyCurrentBranch > overrides the safeguard. Presumably, the user has experience and > knowledge to know that "git reset --hard" will be required to sync > things up.
Or the user knows that he does not have a shell access to the box in the first place. I do not see much relevance to this discussion.
I would not mind "git worktree add -f" to disable the "no multiple checkouts of the same branch" safety, but I do not think it is sensible to remove "-i-o-w" and conflate everything into "--force". That would force people to disable other safety measures at the same time (e.g. protect local changes from differences between the current and next branches).