git@vger.kernel.org mailing list mirror (one of many)
 help / Atom feed
From: Stefan Beller <sbeller@google.com>
To: Shani.Fridman@visionmap.com
Cc: git <git@vger.kernel.org>
Subject: Re: submodules : switching to an older commit/Tag in project with submodules
Date: Thu, 16 Aug 2018 07:56:52 -0700
Message-ID: <CAGZ79kbqb1b3hPhEzRRvjH65iUXkisfaFyX9EOet6ypWQEFm4A@mail.gmail.com> (raw)
In-Reply-To: <bc9762aaf57e441e95f9eed4e64799b7@EX13.visionmap.co.il>

On Thu, Aug 16, 2018 at 4:55 AM Shani Fridman
<Shani.Fridman@visionmap.com> wrote:
>
>
> Hi everybody,
>
> I've got a question regarding submodules -
>
> I'm working on a git project with submodules connected to it, and pulling changes from them every month (more or less).
> Sometimes I need to checkout older versions of the project (tags or specific commits), that needs the older versions of the submodules as they were when I defined the tag. The problem is, that the checkout only changes the superProject directories, and not the submodules... I have to checkout the relevant submodules commit manually.
>
> Have you came across the same problem? Any idea what can I do?

git checkout learned about the --recurse-submodules flag some time
ago. If that is what you need, just set 'git config submodule.recurse
true' so you don't have to pass that flag every time.

Hope that helps,
Stefan

  reply index

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-16 10:54 Shani Fridman
2018-08-16 14:56 ` Stefan Beller [this message]
2018-08-16 18:13 ` Ævar Arnfjörð Bjarmason
2018-08-16 18:18   ` Junio C Hamano
2018-08-16 18:41     ` Ævar Arnfjörð Bjarmason

Reply instructions:

You may reply publically 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=CAGZ79kbqb1b3hPhEzRRvjH65iUXkisfaFyX9EOet6ypWQEFm4A@mail.gmail.com \
    --to=sbeller@google.com \
    --cc=Shani.Fridman@visionmap.com \
    --cc=git@vger.kernel.org \
    /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

git@vger.kernel.org mailing list mirror (one of many)

Archives are clonable:
	git clone --mirror https://public-inbox.org/git
	git clone --mirror http://ou63pmih66umazou.onion/git
	git clone --mirror http://czquwvybam4bgbro.onion/git
	git clone --mirror http://hjrcffqmbrq6wope.onion/git

Newsgroups are available over NNTP:
	nntp://news.public-inbox.org/inbox.comp.version-control.git
	nntp://ou63pmih66umazou.onion/inbox.comp.version-control.git
	nntp://czquwvybam4bgbro.onion/inbox.comp.version-control.git
	nntp://hjrcffqmbrq6wope.onion/inbox.comp.version-control.git
	nntp://news.gmane.org/gmane.comp.version-control.git

 note: .onion URLs require Tor: https://www.torproject.org/
       or Tor2web: https://www.tor2web.org/

AGPL code for this site: git clone https://public-inbox.org/ public-inbox