git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: Joey Hess <id@joeyh.name>
Cc: "git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: bug: git submodule add fails when .git is a symlink
Date: Wed, 2 Mar 2016 03:49:04 -0500	[thread overview]
Message-ID: <20160302084904.GA30295@sigill.intra.peff.net> (raw)
In-Reply-To: <20160301231720.GB3731@kitenet.net>

On Tue, Mar 01, 2016 at 07:17:20PM -0400, Joey Hess wrote:

> Junio C Hamano wrote:
> > A more pertinent question may be which version of Git did the above
> > ever work, I guess.  We fairly liberally chdir around and I do not
> > think we deliberately avoid assuming that "cd .git && cd .." might
> > not come back to the original directory, for example, so I wouldn't
> > be surprised if it never worked.
> 
> IIRC git used symlinks for .git in submodules before version 1.7.8, so I
> guess that older versions supported that pretty well.
> 
> This one case is the only time I've seen a symlink for .git present a
> problem so far.

Fortunately you provided a simple reproduction case, so it is easy to
bisect. It did work in v1.7.8, and broke in d75219b (submodules: always
use a relative path from gitdir to work tree, 2012-03-04). Not
surprising, I guess. It presumably worked before only because we were
using absolute paths.

-Peff

  reply	other threads:[~2016-03-02  8:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-03-01 20:42 bug: git submodule add fails when .git is a symlink Joey Hess
2016-03-01 21:39 ` Stefan Beller
2016-03-01 21:49   ` Stefan Beller
2016-03-01 23:14     ` Joey Hess
2016-03-01 21:50   ` Junio C Hamano
2016-03-01 23:17     ` Joey Hess
2016-03-02  8:49       ` Jeff King [this message]
2016-04-20 16:41         ` Stefan Beller
2016-04-20 17:31           ` Stefan Beller

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

  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=20160302084904.GA30295@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=id@joeyh.name \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).