Git development
 help / color / mirror / Atom feed
From: "Sean" <seanlkml@sympatico.ca>
To: "H. Peter Anvin" <hpa@zytor.com>
Cc: "David Woodhouse" <dwmw2@infradead.org>,
	tglx@linutronix.de, git@vger.kernel.org,
	"Linus Torvalds" <torvalds@osdl.org>
Subject: Re: History messup
Date: Mon, 9 May 2005 18:08:59 -0400 (EDT)	[thread overview]
Message-ID: <3772.10.10.10.24.1115676539.squirrel@linux1> (raw)
In-Reply-To: <427FBB53.1000801@zytor.com>

On Mon, May 9, 2005 3:34 pm, H. Peter Anvin said:
> I'm particularly thinking of when you copy and clone directories, you
> have to define your semantics more specifically.  When do you want to
> *copy* this ID, and when do you want to make sure a new one is created?

What question will a repoid let you answer?

Isn't the real problem, where to store "repoid"?  Obviously it would be
stored in each commit created in a repo, but that's not really the
problem.   The problem is identifying which repo each branch belongs to as
you traverse the history.  This lets you ask questions like, "was this
commit created on this branch, or is it just a copy".

But just as the committer information in each object doesn't help you
identify the branch, nor will having a repoid inside each commit.   The
problem is labelling the branch, not the commits found in it.  And there
is no place to store the repoid for each branch.

Using the repoid of the first commit found on a branch is pretty close,
but fails because it might be a fast-forward HEAD rather than a genuine
local commit of the source repository.  So there is no way to know as you
embark down a branch its repoid, so you have nothing to compare against
the repoid inside each commit you find along its path.

Seems the only solution is a full search of the history, unless there is
some clever way to label branches or detect fast forward heads.

> One possible answer to that is to have .git/repoid and have it
> auto-created (from /dev/urandom) if it doesn't exist, but I also observe
> that at least two people (davem and pavel) have managed to clone "Linus'
> kernel tree" as their description on http://www.kernel.org/git/ ...

:o)

sean



  reply	other threads:[~2005-05-09 22:01 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-09 16:59 History messup Thomas Gleixner
2005-05-09 17:06 ` Thomas Glanzmann
2005-05-09 18:05   ` Thomas Gleixner
2005-05-09 17:27 ` David Woodhouse
2005-05-09 17:48   ` Thomas Gleixner
2005-05-09 19:01     ` H. Peter Anvin
2005-05-09 19:06       ` David Woodhouse
2005-05-09 19:34         ` H. Peter Anvin
2005-05-09 22:08           ` Sean [this message]
2005-05-11 17:09             ` Thomas Gleixner
2005-05-11 20:31         ` Petr Baudis

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=3772.10.10.10.24.1115676539.squirrel@linux1 \
    --to=seanlkml@sympatico.ca \
    --cc=dwmw2@infradead.org \
    --cc=git@vger.kernel.org \
    --cc=hpa@zytor.com \
    --cc=tglx@linutronix.de \
    --cc=torvalds@osdl.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