From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.bugs Subject: bug#20292: 24.5; Saving Git-controlled file with merge conflicts after "stash pop" stages the file Date: Fri, 15 May 2015 16:02:03 -0400 Message-ID: References: <83fv88ta5r.fsf@gnu.org> <838udm61ur.fsf@gnu.org> <5536FE56.406@yandex.ru> <83egnc4nu5.fsf@gnu.org> <55528906.7060606@yandex.ru> <83zj58jvri.fsf@gnu.org> <834mnfjjlz.fsf@gnu.org> <5554DBB2.3070005@yandex.ru> <83mw17huqr.fsf@gnu.org> <5554EDF5.5050606@yandex.ru> <83iobvhtzw.fsf@gnu.org> <5554F2F3.6010109@yandex.ru> <83fv6zhs3j.fsf@gnu.org> <55550482.1020404@yandex.ru> <83bnhmia75.fsf@gnu.org> <83mw15hdqn.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1431720204 7240 80.91.229.3 (15 May 2015 20:03:24 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 15 May 2015 20:03:24 +0000 (UTC) Cc: esr@snark.thyrsus.com, 20292@debbugs.gnu.org, dgutov@yandex.ru To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Fri May 15 22:03:12 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1YtLp9-00069w-Jg for geb-bug-gnu-emacs@m.gmane.org; Fri, 15 May 2015 22:03:11 +0200 Original-Received: from localhost ([::1]:32903 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YtLp8-0000kr-QR for geb-bug-gnu-emacs@m.gmane.org; Fri, 15 May 2015 16:03:10 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49072) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YtLp4-0000km-Bs for bug-gnu-emacs@gnu.org; Fri, 15 May 2015 16:03:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YtLp0-0000pO-FQ for bug-gnu-emacs@gnu.org; Fri, 15 May 2015 16:03:06 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:36503) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YtLp0-0000pI-Bs for bug-gnu-emacs@gnu.org; Fri, 15 May 2015 16:03:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1YtLoz-0007jW-TP for bug-gnu-emacs@gnu.org; Fri, 15 May 2015 16:03:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stefan Monnier Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 15 May 2015 20:03:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 20292 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 20292-submit@debbugs.gnu.org id=B20292.143172015029683 (code B ref 20292); Fri, 15 May 2015 20:03:01 +0000 Original-Received: (at 20292) by debbugs.gnu.org; 15 May 2015 20:02:30 +0000 Original-Received: from localhost ([127.0.0.1]:46478 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YtLoT-0007ih-TD for submit@debbugs.gnu.org; Fri, 15 May 2015 16:02:30 -0400 Original-Received: from mercure.iro.umontreal.ca ([132.204.24.67]:37854) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1YtLoR-0007iY-I0 for 20292@debbugs.gnu.org; Fri, 15 May 2015 16:02:28 -0400 Original-Received: from hidalgo.iro.umontreal.ca (hidalgo.iro.umontreal.ca [132.204.27.50]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id 8A4269C14E; Fri, 15 May 2015 16:02:26 -0400 (EDT) Original-Received: from lechon.iro.umontreal.ca (lechon.iro.umontreal.ca [132.204.27.242]) by hidalgo.iro.umontreal.ca (Postfix) with ESMTP id EE7291E5B96; Fri, 15 May 2015 16:02:03 -0400 (EDT) Original-Received: by lechon.iro.umontreal.ca (Postfix, from userid 20848) id CB754B409F; Fri, 15 May 2015 16:02:03 -0400 (EDT) In-Reply-To: <83mw15hdqn.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 15 May 2015 21:55:44 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-2.82, requis 5, autolearn=not spam, ALL_TRUSTED -2.82, MC_TSTLAST 0.00) X-DIRO-MailScanner-From: monnier@iro.umontreal.ca X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:102841 Archived-At: >> > That's not the use case we were discussing, though. We were >> > discussing a use case where the user merged from another repository, >> > and then wants her uncommitted changes restored. Leaving them staged >> > will trip the naive users. >> But Emacs is not the main culprit: Git itself will stage all the >> non-conflicting changes, so why should this not trip the user similarly? > The users I have in mind expect Emacs to save them from Git > idiosyncrasies. I don't see how that's relevant. By behaving differently from the rest of Git, I'm afraid we'll just introduce more problems. >> IOW if the user gets tripped by Emacs doing "git add" after resolving >> a unstash conflict, why would that same user not already be tripped >> identically by Git doing this "git add" on the non-conflicted files? > Because they don't use Git from the shell, or at least try not to. Feel free to change the behavior of vc-git-resolve-when-done for the case where the unstash was done from within Emacs after you've changed this unstash to behave the way you want it, rather than the way Git does it. In my case, the unstash is done by Git with no Emacs involvement, and in that case it seems that "git add" is just the only sane thing to do. Stefan