All of lore.kernel.org
 help / color / mirror / Atom feed
From: Johannes Schindelin <Johannes.Schindelin@gmx.de>
To: Philippe Blain <levraiphilippeblain@gmail.com>
Cc: Phillip Wood via GitGitGadget <gitgitgadget@gmail.com>,
	git@vger.kernel.org, Phillip Wood <phillip.wood@dunelm.org.uk>,
	Emily Shaffer <emilyshaffer@google.com>
Subject: Re: [PATCH 4/5] rebase -i: don't fork git checkout
Date: Thu, 9 Sep 2021 12:53:17 +0200 (CEST)	[thread overview]
Message-ID: <nycvar.QRO.7.76.6.2109091250540.59@tvgsbejvaqbjf.bet> (raw)
In-Reply-To: <f05dc55f-a7e4-b8f7-7b0c-5000bf48f803@gmail.com>

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

Hi Philippe,

On Wed, 8 Sep 2021, Philippe Blain wrote:

> Hi Phillip,
>
> Le 2021-09-08 à 09:41, Phillip Wood via GitGitGadget a écrit :
> > From: Phillip Wood <phillip.wood@dunelm.org.uk>
> >
> > The "apply" based rebase has avoided forking git checkout since
> > ac7f467fef ("builtin/rebase: support running "git rebase <upstream>"",
> > 2018-08-07). The code that handles the checkout was moved into libgit
> > by b309a97108 ("reset: extract reset_head() from rebase", 2020-04-07)
> > so lets start using it for the "merge" based rebase as well. This
> > opens the way for us to stop calling the post-checkout hook in the
> > future.
> >
>
> While in general I think it's a good thing to avoid forking, this change
> might result in behavioral differences. Any config that affects
> 'git checkout' but not the internal 'reset.c::reset_head' function might
> play a role in the rebase UX.
>
> One that immediately came to mind is 'submodule.recurse'. This initial
> 'onto' checkout was pretty much the only part of 'git rebase' that did
> something useful for submodules, so it's kind of sad to see it regress.
> [That is, until someone takes the time to implement 'git rebase
> --recurse-submodules' and makes sure *all* code paths that touch the
> working tree pay attention to this flag, and that will probably
> necessitate 'git merge --recurse-submodules' first because of the
> 'merge' backend... as far as I'm aware it's on Emily's list [1], it's
> also on mine but I don't know when I'll get the time.]

Good point, there is more in the `git_checkout_config()` function (which
is `static` in `builtin/checkout.c`, and could easily be moved to
`checkout.[ch]`). We should probably fall back to calling that function
rather than `git_default_config()` in `rebase_config()`.

> Anyway, I'm not saying that we should not do what this patch is
> proposing, but I think caveats such as that should be documented in the
> commit message, and maybe an audit of other configs that might results
> in behavioural differences should be done.

Since this is already a bug in the `apply` backend, it would be even
better to follow-up with a fix, hint, hint, nudge, nudge ;-)

Ciao,
Dscho

  parent reply	other threads:[~2021-09-09 10:53 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-08 13:41 [PATCH 0/5] rebase -i: a couple of small improvements Phillip Wood via GitGitGadget
2021-09-08 13:41 ` [PATCH 1/5] sequencer.c: factor out a function Phillip Wood via GitGitGadget
2021-09-08 17:51   ` Eric Sunshine
2021-09-09 10:10     ` Phillip Wood
2021-09-09 10:44   ` Johannes Schindelin
2021-09-08 13:41 ` [PATCH 2/5] rebase: fix todo-list rereading Phillip Wood via GitGitGadget
2021-09-09 10:48   ` Johannes Schindelin
2021-09-08 13:41 ` [PATCH 3/5] reset_head(): mark oid parameter as const Phillip Wood via GitGitGadget
2021-09-08 13:41 ` [PATCH 4/5] rebase -i: don't fork git checkout Phillip Wood via GitGitGadget
2021-09-08 18:14   ` Philippe Blain
2021-09-09 10:09     ` Phillip Wood
2021-09-09 12:40       ` Philippe Blain
2021-09-09 13:57         ` Phillip Wood
2021-09-09 15:01           ` Elijah Newren
2021-09-10 12:07             ` Philippe Blain
2021-09-15 15:44             ` Phillip Wood
2021-09-09 10:53     ` Johannes Schindelin [this message]
2021-09-09 12:44       ` Philippe Blain
2021-09-09 21:43         ` Johannes Schindelin
2021-09-10 10:46         ` Johannes Schindelin
2021-09-10 11:58           ` Philippe Blain
2021-09-09 15:03   ` Elijah Newren
2021-09-08 13:41 ` [PATCH 5/5] rebase: remove unused parameter Phillip Wood via GitGitGadget
2021-09-09 10:54   ` Johannes Schindelin
2021-09-09 14:04     ` Phillip Wood
2021-09-23 15:26 ` [PATCH v2 0/2] rebase -i: a couple of small improvements Phillip Wood via GitGitGadget
2021-09-23 15:26   ` [PATCH v2 1/2] sequencer.c: factor out a function Phillip Wood via GitGitGadget
2021-09-23 15:26   ` [PATCH v2 2/2] rebase: fix todo-list rereading Phillip Wood via GitGitGadget
2021-09-24 16:13     ` Junio C Hamano
2021-09-28 10:20       ` Phillip Wood
2021-09-24 19:24   ` [PATCH v2 0/2] rebase -i: a couple of small improvements 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=nycvar.QRO.7.76.6.2109091250540.59@tvgsbejvaqbjf.bet \
    --to=johannes.schindelin@gmx.de \
    --cc=emilyshaffer@google.com \
    --cc=git@vger.kernel.org \
    --cc=gitgitgadget@gmail.com \
    --cc=levraiphilippeblain@gmail.com \
    --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.