git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andreas Ericsson <ae@op5.se>
To: Michael Witten <mfwitten@gmail.com>
Cc: rdiezmail-temp2@yahoo.de, Thomas Rast <trast@student.ethz.ch>,
	in-git-vger@baka.org, Michael J Gruber <git@drmicha.warpmail.net>,
	Jonathan Nieder <jrnieder@gmail.com>,
	Hilco Wijbenga <hilco.wijbenga@gmail.com>,
	git@vger.kernel.org
Subject: Re: How to check out the repository at a particular point in time
Date: Wed, 24 Aug 2011 17:41:55 +0200	[thread overview]
Message-ID: <4E551BC3.8080701@op5.se> (raw)
In-Reply-To: <CAMOZ1Bti3ZtAEOtLiUYSkWE+rO_VQd09NAn58Cn4hZBu8f-aFQ@mail.gmail.com>

On 08/23/2011 05:54 PM, Michael Witten wrote:
> On Mon, Aug 22, 2011 at 15:18, R. Diez<rdiezmail-temp2@yahoo.de>  wrote:
>>> The main problem is that your request is not very
>>> well-defined: in
>>> nonlinear history there will in general be more than one
>>> commit at the
>>> time requested.
>>>
>>>      ---a----b----c----M----  (M is a merge)
>>>          \            /
>>>           d-----e----f
>>>
>>>               ^----April 1st
>>>
>>> Suppose you ask git for "the newest commit as of April 1st"
>>> in this history.  Is it supposed to give you b or d?
>>
>> I still don't quite understand how git works, but let me
>> risk a naive statement here. If "a-b-c-M" were 'master',
>> and "d-e-f" were 'new-feature', then on April 1st the
>> current version on 'master' is 'b', because I merged the
>> 'new-feature' branch at a later point in time. Does that
>> make sense?
> 
> O! for the love all that is Holy!
> 
> You see, guys? The term `branch' was a TERRIBLE choice.
> 
> What git calls `branch master' in your example is just a pointer to
> the commit object `M'; it has nothing to do with particular lineages
> like `a-b-c-M'.
> 

Back in 2005 when git was young and fresh, there was a discussion about
what to call things. If memory serves (which it might not), I think
the consensus was that "branch" works just fine, and when someone who
doesn't like it comes along we can just tell them that it's short for
"tip-of-branch pointer", which is far more accurate. A "ref" is always
local though, which is why the reflog (which is used for such date
resolving problems) is never even considered to work on remote refs.
They *can* work on remotes' refs though, which is a slightly different
thing.

Whatever, really. The fact that pretty much everyone seems to know
what a branch is and how it works in git after a (very) brief intro
to it means it's either right on target or that people are so used to
the fact that branch means something different in every scm that they
don't even bother loading the word with some preconceived notion that
used to be right in cvs.

-- 
Andreas Ericsson                   andreas.ericsson@op5.se
OP5 AB                             www.op5.se
Tel: +46 8-230225                  Fax: +46 8-230231

Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.

  parent reply	other threads:[~2011-08-24 15:42 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-22 12:25 How to check out the repository at a particular point in time R. Diez
2011-08-22 13:25 ` Thomas Rast
2011-08-22 15:18   ` R. Diez
2011-08-22 16:56     ` Jens Lehmann
2011-08-23 15:54     ` Michael Witten
2011-08-23 16:05       ` Jonathan Nieder
2011-08-23 16:09         ` Matthieu Moy
2011-08-23 16:23           ` Michael Witten
2011-08-23 16:53             ` Jonathan Nieder
2011-08-24 15:41       ` Andreas Ericsson [this message]
2011-08-24 15:48         ` Randal L. Schwartz
2011-08-24 16:18           ` Michael Witten
  -- strict thread matches above, loose matches on Subject: below --
2011-08-23  7:41 R. Diez
2011-08-23  9:17 ` Thomas Rast
2011-08-23 10:04   ` PJ Weisberg
2011-08-23 20:30     ` Jens Lehmann

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=4E551BC3.8080701@op5.se \
    --to=ae@op5.se \
    --cc=git@drmicha.warpmail.net \
    --cc=git@vger.kernel.org \
    --cc=hilco.wijbenga@gmail.com \
    --cc=in-git-vger@baka.org \
    --cc=jrnieder@gmail.com \
    --cc=mfwitten@gmail.com \
    --cc=rdiezmail-temp2@yahoo.de \
    --cc=trast@student.ethz.ch \
    /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).