public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox•com>
To: Philippe Blain <levraiphilippeblain@gmail•com>
Cc: "Bech Christensen, Søren" <Soeren.Bech@bitzerdk•com>,
	"git@vger•kernel.org" <git@vger•kernel.org>
Subject: Re: Possible bug in Git submodule update --inti
Date: Tue, 19 Nov 2024 09:32:02 +0900	[thread overview]
Message-ID: <xmqqldxghxml.fsf@gitster.g> (raw)
In-Reply-To: <8db6eba3-a151-3819-159b-921a6c3f3242@gmail.com> (Philippe Blain's message of "Mon, 18 Nov 2024 14:22:18 -0500")

Philippe Blain <levraiphilippeblain@gmail•com> writes:

> Hi Søren,
> ...
> in the doc for 'git submodule init' [3]. Note that this is _not_ 
> the exact command that you ran according to the trace output below, which is:
> ...
> I think what you'd want to do is simply:
>
> git submodule set-url -- <path-to-submodule> <new-url> 
> git submodule update --init --remote
>
> This will fetch the new URL and checkout the tip commit of its HEAD branch.
> You will still have all the objects from the old URL locally though. If you want
> to avoid that, you should completely remove the Git repository of the submodule:
>
> git submodule set-url -- <path-to-submodule> <new-url> 
> git submodule deinit -f <path-to-submodule>
> rm -rf $(git rev-parse --git-dir)/modules/Submodules/Lodam.Standard
> git submodule update --init --remote

Thanks for a pleasant exchange, RFH with sufficient information
necessary to help, with a detailed diagnosis and an alternative
offered.

      reply	other threads:[~2024-11-19  0:32 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-18  8:14 Possible bug in Git submodule update --inti Bech Christensen, Søren
2024-11-18 19:22 ` Philippe Blain
2024-11-19  0:32   ` Junio C Hamano [this message]

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=xmqqldxghxml.fsf@gitster.g \
    --to=gitster@pobox$(echo .)com \
    --cc=Soeren.Bech@bitzerdk$(echo .)com \
    --cc=git@vger$(echo .)kernel.org \
    --cc=levraiphilippeblain@gmail$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox