Re: [PATCH v2] submodule: resolve insteadOf aliases when matching remote

Jacob Keller <[email protected]>
Newsgroups org.kernel.vger.git
Message-ID <CA+P7+xpADY-cfzfjmaXboJMdQfcjRLFNoxhWf4weU00-Q0g2rA@mail.gmail.com>
On Fri, Jul 24, 2026 at 1:36 PM Junio C Hamano <[email protected]> wrote:
>
> Éric NICOLAS <[email protected]> writes:
>
> > - Reword the commit message more purposefully
> > - Adjust the implementation as suggested, avoiding a superfluous
> >   variable
> > - Tidy up the integration test
>
> Queued.
>
> Is everybody happy with this version?
>
> Thanks.

Yes, consider it:

Reviewed-by: Jacob Keller <[email protected]>

Appreciate the fix, I think I had ran into this at some point and it
got put on a pile of "to finish debugging later" and never fixed.
Thanks!

>
> > diff --git a/t/t7406-submodule-update.sh b/t/t7406-submodule-update.sh
> > index 9554720152..10adeabf0f 100755
> > --- a/t/t7406-submodule-update.sh
> > +++ b/t/t7406-submodule-update.sh
> > @@ -256,6 +256,25 @@ test_expect_success 'submodule update --remote should fetch upstream changes' '
> >       )
> >  '
> >
> > +test_expect_success 'submodule update --remote resolves URL rewrites' '
> > +     test_config_global "url.$(pwd)/.insteadOf" local: &&
> > +     mkdir alias-super alias-submodule &&
> > +     (
> > +             cd alias-submodule &&
> > +             git init &&
> > +             git commit --allow-empty --message "Initial commit"
> > +     ) &&
> > +     (
> > +             cd alias-super &&
> > +             git init &&
> > +             git submodule add local:alias-submodule submodule &&
> > +             git submodule update --force &&
> > +             git -C submodule remote rename origin upstream &&
> > +             git -C submodule remote add fork user@host &&
> > +             git submodule update --remote
> > +     )
> > +'
>
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.