git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "brian m. carlson" <sandals@crustytoothpaste.net>
To: Robin Dos Anjos <robin_1997@hotmail.fr>
Cc: "git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: General question about "git range-diff"
Date: Thu, 2 Nov 2023 21:48:07 +0000	[thread overview]
Message-ID: <ZUQZF-4CW-FbjfAU@tapette.crustytoothpaste.net> (raw)
In-Reply-To: <PR3P195MB087847E68AD2032148EFCA039BA6A@PR3P195MB0878.EURP195.PROD.OUTLOOK.COM>

[-- Attachment #1: Type: text/plain, Size: 2022 bytes --]

On 2023-11-02 at 18:56:39, Robin Dos Anjos wrote:
> Hi git community!

Hi,

> I'm a bit intimidated as this is my first message in the mailing list but I'll give it a go!

No reason to be intimidated.  We're very friendly here.

> This is so useful to me that I'm wondering why "git range-diff" does
> not implement this behavior. We could imagine a flag that would make
> it behave as I described. Is this something that was ever considered?
> Are there any technical difficulties that I'm completely missing? Do
> you think this could be helpful to other people?

I'm not the author of range-diff, but I believe it was based on an
earlier tool named git-tbdiff[0], which had similar behaviour and
similar limitations.  My guess as to why nobody implemented a feature to
handle the squashed commits case is that typically the recommended
workflow in Git is to write small independent, logical, well-described,
bisectable commits, and squashing is not recommended because it destroys
all the work that people have put into making nice commits.

Of course, in many situations, people don't write nice commits like
that, and many commits are effectively fixup commits with very short
messages (e.g. "make it work"), sometimes containing profanity directed
at the computer, and in those environments, squashing may be a
legitimate choice.  However, it isn't typically a workflow that gets a
lot of focus because most tooling is focused on the more recommended
approach.

Having said that, I'm sure people would find a feature like you
suggested useful, although I'm not likely to use it myself.  It's
possible that somebody might see your message and implement it, but
usually patches come in from people who feel strongly about a feature
and implement it themselves.  If you feel like you'd like to try such a
change, I'm sure you can find folks to review it and provide feedback.

[0] https://github.com/trast/tbdiff
-- 
brian m. carlson (he/him or they/them)
Toronto, Ontario, CA

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 262 bytes --]

  reply	other threads:[~2023-11-02 21:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-02 18:56 General question about "git range-diff" Robin Dos Anjos
2023-11-02 21:48 ` brian m. carlson [this message]
2023-11-02 23:21 ` Junio C Hamano
2023-11-03  1:25   ` Robin Dos Anjos

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZUQZF-4CW-FbjfAU@tapette.crustytoothpaste.net \
    --to=sandals@crustytoothpaste.net \
    --cc=git@vger.kernel.org \
    --cc=robin_1997@hotmail.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).