All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jason Wang <jason77.wang@gmail.com>
To: <git@vger.kernel.org>
Subject: help: the question about relative path in the objects/info/alternates
Date: Mon, 1 Aug 2011 17:16:56 +0800	[thread overview]
Message-ID: <4E366F08.2060808@gmail.com> (raw)

Hi git experts,

 From the objects/info/alternates part of this URL 
http://www.kernel.org/pub/software/scm/git/docs/gitrepository-layout.html, 
it says it will work if alternates has relative path in it. But i found 
it will always fail under below situation, i don't know whether the 
failure is due to the git nature or it is a git potential bug.

The failure situation is like that:
On my machine, i have a git bare base repository, e.g. 
/home/jason/source/base-bare. On the same machine, i have a git bare 
incremental (it need to refer to base repository) repository, e.g. 
/home/jason/source/incremental-bare. In the 
incremental-bare/objects/info/alternates, i set a relative path to point 
to the objects of base-bare like this "../../base-bare/objects". Then i 
want to clone a new repository from the incremental-bare on the same 
machine, if i use this command "git clone 
/home/jason/source/incremental-bare new-project", it will fail; but if i 
use this command "git clone file:///home/jason/source/incremental-bare 
new-project", it will work successfully, Why the first one can't work, 
it is a bug for git?

In addtion, if i write an absolute path in the 
incremental-bare/objects/info/alternates like this 
"/home/jason/source/base-bare/objects", it will always work well no 
matter i add or don't add "file://".

Thanks
Jason Wang.

             reply	other threads:[~2011-08-01  9:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-01  9:16 Jason Wang [this message]
2011-08-01 17:44 ` help: the question about relative path in the objects/info/alternates Junio C Hamano
2011-08-02  7:15   ` Jason Wang

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=4E366F08.2060808@gmail.com \
    --to=jason77.wang@gmail.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
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.