From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: git pre-commit hook for merges (WAS: master has switched from Automake to GNU Make) Date: Sat, 29 Apr 2017 23:04:30 +0300 Message-ID: <83mvazkmk1.fsf@gnu.org> References: <955c464e-5833-10fd-9c02-d7edda70e488@cs.ucla.edu> <83shkrkote.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1493496350 27303 195.159.176.226 (29 Apr 2017 20:05:50 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 29 Apr 2017 20:05:50 +0000 (UTC) Cc: rudalics@gmx.at, yuri.v.khan@gmail.com, eggert@cs.ucla.edu, schwab@suse.de, emacs-devel@gnu.org To: Noam Postavsky Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Apr 29 22:05:45 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1d4Yci-0006xQ-Rk for ged-emacs-devel@m.gmane.org; Sat, 29 Apr 2017 22:05:44 +0200 Original-Received: from localhost ([::1]:42306 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d4Ycn-0004YL-6O for ged-emacs-devel@m.gmane.org; Sat, 29 Apr 2017 16:05:49 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41319) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d4YcB-0004YF-Ur for emacs-devel@gnu.org; Sat, 29 Apr 2017 16:05:12 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1d4YcB-0006zd-4u for emacs-devel@gnu.org; Sat, 29 Apr 2017 16:05:11 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:34795) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1d4Yc4-0006uH-Sa; Sat, 29 Apr 2017 16:05:04 -0400 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:1534 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1d4Yc3-0005R9-In; Sat, 29 Apr 2017 16:05:04 -0400 In-reply-to: (message from Noam Postavsky on Sat, 29 Apr 2017 15:54:41 -0400) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2001:4830:134:3::e X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:214426 Archived-At: > From: Noam Postavsky > Date: Sat, 29 Apr 2017 15:54:41 -0400 > Cc: Paul Eggert , martin rudalics , > Emacs developers , Andreas Schwab , Yuri Khan > > On Sat, Apr 29, 2017 at 3:15 PM, Eli Zaretskii wrote: > >> > Since git only runs the hooks on the merged changes when you pass > >> > --no-commit to 'git merge', defaulting to non-blind merge doesn't > >> > really work anyway. > >> > >> Thanks for looking into this. I guess I'll have to rethink how I merge. > > > > Not sure it matters in the context of this discussion, but please keep > > in mind that "git cherry-pick" also merges. > > My intuition is that getting a commit hook failure from the commit > being cherry picked will be less confusing than getting hook failures > from one of the many commits being merged from a branch, so I don't > think it's worth updating the hook to avoid this case. I don't think I agree. In fact, I think many users will not even realize that cherry-pick merges, and will be surprised. > 'git cherry-pick' does have the same issue as 'git merge': it won't > rerun the commit hook, unless '--no-commit' is passed Too bad. I wish this could be fixed as well.