All of lore.kernel.org
 help / color / mirror / Atom feed
From: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
To: phillip.wood@dunelm.org.uk
Cc: Johannes Sixt <j6t@kdbg.org>, git@vger.kernel.org
Subject: Re: using oldest date when squashing commits
Date: Tue, 24 Oct 2023 12:18:04 +0200	[thread overview]
Message-ID: <ZTeZ3KEQLIVU/sq2@ugly> (raw)
In-Reply-To: <a99b16a8-a06c-4d38-bb78-46ce17411597@gmail.com>

On Tue, Oct 24, 2023 at 10:26:29AM +0100, Phillip Wood wrote:
>On 20/03/2022 08:05, Johannes Sixt wrote:
>> Am 19.03.22 um 13:48 schrieb Oswald Buddenhagen:
>>> during interactive rebasing, i sometimes find it necessary to move a
>>> hunk from one commit to a later one in the branch. now, if that hunk
>>> cannot be re-ordered with the later commit due to conflicting with it,
>>> it becomes necessary to squash the later commit onto a temporary commit
>>> created from the extracted hunk, not the other way around (or using a
>>> stash). unfortunately, this causes the author date of the later commit
>>> to be reset, which can rather seriously falsify the date if the branch
>>> is long-lived.
>> 
>> You want `fixup -C` in the todo-list. See the hints near the end of the
>> todo-list.
>
>Unfortunately "fixup -C" only copies the commit message not the 
>authorship

>(that's usually a good thing
>
why? what would that be useful for? it seems rather counter-intuitive.
it's also inconsistent with commit -c/-C's behavior, which seems like a 
red flag to me.

>but not it means it wont work for what Oswald wants to do).

>Maybe we should add another flag for fixup/squash commands to take the 
>authorship from that commit.
>
that's a possibility. but given the above, it might be better to simply 
change the behavior of -c/-C to keep the UI lean and consistent with 
commit's behavior.

regards

  reply	other threads:[~2023-10-24 10:18 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-19 12:48 using oldest date when squashing commits Oswald Buddenhagen
2022-03-20  8:05 ` Johannes Sixt
2022-03-20 10:53   ` Oswald Buddenhagen
2023-10-24  9:26   ` Phillip Wood
2023-10-24 10:18     ` Oswald Buddenhagen [this message]
2023-10-24 14:00       ` Phillip Wood
2023-10-24 17:30         ` Junio C Hamano
2023-10-24 20:13           ` Oswald Buddenhagen
2023-10-24 21:19           ` Johannes Sixt
2023-10-27 12:34             ` Marc Branchaud
2023-10-27 12:45               ` Oswald Buddenhagen
2023-10-27 13:20                 ` Marc Branchaud
2023-10-27 13:26                   ` Oswald Buddenhagen
2023-10-27 13:46                     ` Marc Branchaud
2023-10-27 23:24               ` Junio C Hamano

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

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

  git send-email \
    --in-reply-to=ZTeZ3KEQLIVU/sq2@ugly \
    --to=oswald.buddenhagen@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=j6t@kdbg.org \
    --cc=phillip.wood@dunelm.org.uk \
    /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.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.