From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.devel Subject: Re: New Git hooks for checking file names in commit messages Date: Sat, 22 Apr 2023 09:16:51 +0300 Message-ID: <83o7ng30h8.fsf@gnu.org> References: <838rel46ou.fsf@gnu.org> <865y9ptfa3.fsf@aarsen.me> <83354t44kn.fsf@gnu.org> <86mt31rys2.fsf@aarsen.me> <83ttx92kri.fsf@gnu.org> <86v8hpqfx7.fsf@aarsen.me> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="21713"; mail-complaints-to="usenet@ciao.gmane.io" Cc: acm@muc.de, jporterbugs@gmail.com, emacs-devel@gnu.org To: Arsen =?utf-8?Q?Arsenovi=C4=87?= Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Sat Apr 22 08:17:03 2023 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1pq6YQ-0005Sl-Oq for ged-emacs-devel@m.gmane-mx.org; Sat, 22 Apr 2023 08:17:02 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pq6Y1-0002SW-VN; Sat, 22 Apr 2023 02:16:38 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pq6Xz-0002RV-7T for emacs-devel@gnu.org; Sat, 22 Apr 2023 02:16:35 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pq6Xx-0005XH-K8; Sat, 22 Apr 2023 02:16:33 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=grSGW0QJrvGUZXspey3RWV4vDVjOs07EYtHHEGy54eU=; b=L+KMwGJAVi3QKUx+faK8 RkjBCharbv0Kv7Wbo7yWjBrnolS4jCeiBSjzwZuBw+XEYU+Yd/kDHK3RjHoWb6eMsE1ieDL3Fz78p cKthlTyDqAuffApF18b93OrwhgXqgf7qqDgz5rTfwDZnlwG1xdbYwPsbQZcWQZz0c3huKBdXQlmL4 +lfsYeknaHVLrAQWnjauZERzB1+7KKrqpjjSurWIA+5tUwsDRTt1MkxTPZgd3MQmOIYevcJ50zA5i +M7GfJ2MjlgYKKbJGMv9asIAN1eqQOIOjajKmqLcN15iaRU1k5bl/otIyWDCS6iBCYiSVjTVFrDBV vXLMsjB+QRfbTg==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pq6Xw-0005PZ-Sh; Sat, 22 Apr 2023 02:16:33 -0400 In-Reply-To: <86v8hpqfx7.fsf@aarsen.me> (message from Arsen =?utf-8?Q?Arse?= =?utf-8?Q?novi=C4=87?= on Fri, 21 Apr 2023 19:50:09 +0200) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:305571 Archived-At: > From: Arsen Arsenović > Cc: acm@muc.de, jporterbugs@gmail.com, emacs-devel@gnu.org > Date: Fri, 21 Apr 2023 19:50:09 +0200 > > Eli Zaretskii writes: > > > > > No, "git reset" doesn't rebase. > > No, but it means that everything above the reset point is malleable, in > which case, you can use a rebase on it anyway (which can be reasoned > with as a hard reset with repeated patch application). > > I'm trying to say that it's unnecessary to reset entire histories to > modify some words or formatting in commit messages. No one was talking about "entire histories", we were talking about a single commit that was just made, but not yet pushed. "git reset" is a way to undo the last commit, letting the user to make any changes he/she wants before committing again. So it is (MO) the easiest and safest way of fixing such mistakes. It is why we recommend users to always do a "git show" before pushing, so that they could review what is about to be pushed before actually doing so.