From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Sean Whitton Newsgroups: gmane.emacs.bugs Subject: bug#64055: Implementation of modifying VC change comments for Git Date: Mon, 21 Oct 2024 10:01:28 +0800 Message-ID: <87h696kydj.fsf@melete.silentflame.com> References: <874j59wym3.fsf@melete.silentflame.com> <868qukl73k.fsf@gnu.org> <87bjzfuzaq.fsf@melete.silentflame.com> <96d49abc-888b-4561-b57d-8d85627e2c42@yandex.ru> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20035"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: Morgan.J.Smith@outlook.com, Eli Zaretskii , 64055@debbugs.gnu.org To: Dmitry Gutov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 21 04:02:48 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1t2hkt-00051v-Jz for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 21 Oct 2024 04:02:48 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t2hkk-0005WQ-HJ; Sun, 20 Oct 2024 22:02: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 1t2hkj-0005WF-73 for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2024 22:02:37 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1t2hki-0000tR-Uk for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2024 22:02:36 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=debbugs.gnu.org; s=debbugs-gnu-org; h=MIME-Version:Date:References:In-Reply-To:From:To:Subject; bh=EeFHh05eBxHZjTVvih0Umu3Fwvq8ZETxOkxoMVYPN+0=; b=BXyS4kDsjTRRG96qqnHM74rJl6054u4ouMuS7y/swawMns+x/yTrujkqT9TbzsQ4fkfNJBTI412XkC5QxBbwEXhXc4lKhc21fFQUTLBicMOY6Ym0kuYrV1CLjbZl7jYszeu0v9KLGIrJ4CJMd9rAOyxppsnsG9yubElBj9Bhw77bMCxOUC/EIiCbeo840Izvx3WZuGYrGydY8eQ4G7JWCJ7AoKLW+KXiD+rTrr2TjyNf6H4VmnTp64LxuKdDwgNg2Ag39Qu6kP2Ad/8sJstfX7kVfmzyVieN8tsoL+/WOgTvw6CkgB6KFX9o/ActlRa6nBs5jthQDuVcxvxzKLk49w==; Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1t2hl8-0003FU-Eb for bug-gnu-emacs@gnu.org; Sun, 20 Oct 2024 22:03:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Sean Whitton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 21 Oct 2024 02:03:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64055 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 64055-submit@debbugs.gnu.org id=B64055.172947613012413 (code B ref 64055); Mon, 21 Oct 2024 02:03:02 +0000 Original-Received: (at 64055) by debbugs.gnu.org; 21 Oct 2024 02:02:10 +0000 Original-Received: from localhost ([127.0.0.1]:49484 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t2hkH-0003E8-QG for submit@debbugs.gnu.org; Sun, 20 Oct 2024 22:02:10 -0400 Original-Received: from sendmail.purelymail.com ([34.202.193.197]:60688) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1t2hkG-0003Du-1W for 64055@debbugs.gnu.org; Sun, 20 Oct 2024 22:02:09 -0400 DKIM-Signature: a=rsa-sha256; b=DTWNoGja27cfVLE5SJhewQVVed+WTV4RIChKw2SdS9SkMji774dIkZdRLqyU+DeE7xnm7366GBJ/YUI83gUa1qdp1ed2Y4EYZ41XuiCfElO3utS1SAgPIe5sqO9SlibLfUFIJ72r3Zk/F0v0qPzoCYWx8mKXLhU/Iu1TlMO9cRDdXvRm7SFREd8ItdHLrU80zE75A0HLxs0AgAo8iMFpJcSkK5m1udxrzsw5ACwFbBCUkuGHjgv5sgmoCfL9U4inz+Ria24PPXx+b69tJ3txGskPJHePGhkiXKuG11MByaf7akC8iXlTkv15TunI5FjmXDX4C/yxUb65r2jL5Jr34Q==; s=purelymail1; d=spwhitton.name; v=1; bh=Pa593PjYyqwYFVYS/VMYL3jVeWXNIWbc49JxvNRBiw0=; h=Received:Received:From:To:Subject:Date; DKIM-Signature: a=rsa-sha256; b=nm4NgHKsmZTIfXF1VxRCKX/HpWyJVBju1FmNv0GDB79CqGWUb+gCm8mtN6pblwVPpht+js5RXCZVe/BTsUzSLteRQdNWVd/VBv+CZdeIpjm+grk8We4o0yXm+3FcaDo2HXnnAc+e36DTWzqrANRM7fdTI3yUOZZMs3xp894AWlh4TBrzV+J1+sOFGYslOubGAimwemrPCekBaT6rCER++3kUFWxk/BNyAsHbRA14ZcIed7olOw8/E3k3cAj93vLd2MrluEjuv0ST45+vtOw1iBBVVKqJk8PRIoaRrApX9OIP5yCz6LRTLfhF2QWIzzf1cEQqQznbdLrJ7fVNq+olxA==; s=purelymail1; d=purelymail.com; v=1; bh=Pa593PjYyqwYFVYS/VMYL3jVeWXNIWbc49JxvNRBiw0=; h=Feedback-ID:Received:Received:From:To:Subject:Date; Feedback-ID: 20115:3760:null:purelymail X-Pm-Original-To: 64055@debbugs.gnu.org Original-Received: by smtp.purelymail.com (Purelymail SMTP) with ESMTPSA id -44438419; (version=TLSv1.3 cipher=TLS_AES_256_GCM_SHA384); Mon, 21 Oct 2024 02:01:31 +0000 (UTC) Original-Received: by melete.silentflame.com (Postfix, from userid 1000) id 92BE57EB6AA; Mon, 21 Oct 2024 10:01:28 +0800 (CST) In-Reply-To: <96d49abc-888b-4561-b57d-8d85627e2c42@yandex.ru> (Dmitry Gutov's message of "Mon, 21 Oct 2024 01:09:36 +0100") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:294016 Archived-At: Hello, On Mon 21 Oct 2024 at 01:09am +01, Dmitry Gutov wrote: > On 20/10/2024 08:19, Sean Whitton wrote: >> +*** New user option 'vc-git-allow-rewriting-history'. >> +Many Git commands can change your copy of published change history >> +without warning. If VC commands detect that this could happen, they >> +will stop. You can customize this variable to permit rewriting history >> +even though Emacs thinks it is dangerous. > > Curious: do we consider Git to be different from others? Or would we have > corresponding options for Hg, Bzr, (maybe) Svn? > > If we think rewriting history dangerous for all, we could mark the command as > 'disabled' instead. I think that for some VCS editing the commit message is not a form of rewriting history in any sense. And we can hope for a future VCS that keeps change histories for commit messages, so that we might easily correct our mistakes. So I don't believe it would make sense to just disable log-view-modify-change-comment. We might, though, want to consider a more general vc-allow-rewriting-history instead of vc-git-allow-rewriting-history, and use it wherever its applicable -- it will be VCS-dependent where exactly it applies. I'm cautious about doing that without more information, because "rewriting history" is, in my mind, a Git-specific piece of terminology to begin with. I think it is probably okay to keep vc-git-allow-rewriting-history even if we decide to deprecate it in favour of a more general variable at some point. > Otherwise, seems to work well, even though, as you said, a bit slower than one > might naively expect. Ah, thank you for testing. I'm not whether the slowness is coming from the safety check in vc-git--assert-allowed-rewrite or from the rebase command, or both. I do know that rebases don't tend to be fast. -- Sean Whitton