git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Harald Heigl" <Harald@heigl-online.at>
To: <git@vger.kernel.org>
Subject: What to do if the path of my git submodules change upstream
Date: Wed, 16 Nov 2011 15:37:55 +0100	[thread overview]
Message-ID: <000301cca46d$5428c3d0$fc7a4b70$@heigl-online.at> (raw)

Hi everyone!

First setup of my git was a server (with ssh) and some clients.

Today I changed to gitolite because I wanted a more sophisticated way of
managing my repos. So far so good…
So the old path “ssh://[ip]/[fullpath].git” would change to a new path
“git@[servername]:[gitreponame]”. 
This is no problem for “normal” repos, I change the remote origin and
continue using push and pull.

I have some submodules:
I changed the .gitmodules to reflect my changes, did a git submodule sync.
This works flawlessly too!

But what if someone wants to checkout an older version of the project? (for
comparison, or because he/she wanted to try something out)
He would get an old .gitmodules with old paths.
After a git submodule sync he would get errors, because old paths won’t work
anymore, because I changed some paths on the server 

It is only one project I have this problem and therein I changed the
.gitmodules only 3 times. Is it possible to rewrite .gitmodules on these
specific  commits on the server (perhaps with git-filter-branch)?
Or is there another easy solution? Has someone ever had this problem?

Hope you can help,
Kind regards,
Harald Heigl

             reply	other threads:[~2011-11-16 14:38 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-16 14:37 Harald Heigl [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-11-26 16:45 What to do if the path of my git submodules change upstream Harald Heigl

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='000301cca46d$5428c3d0$fc7a4b70$@heigl-online.at' \
    --to=harald@heigl-online.at \
    --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
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;
as well as URLs for NNTP newsgroup(s).