From: Jakub Narebski <jnareb@gmail.com>
To: git@vger.kernel.org
Subject: [RFD] Git glossary: 'branch' and 'head' description
Date: Wed, 17 May 2006 13:37:19 +0200 [thread overview]
Message-ID: <e4f1ta$e07$1@sea.gmane.org> (raw)
In #git channel somebody asked about 'branches' and 'heads' and was referred
to the glossary. I had taken then a look at appropriate glossary entries.
In 'Documentation/glossary.txt' we have:
----
branch::
A non-cyclical graph of revisions, i.e. the complete history of
a particular revision, which is called the branch head. The
branch heads are stored in `$GIT_DIR/refs/heads/`.
head::
The top of a branch. It contains a ref to the corresponding
commit object.
head ref::
A ref pointing to a head. Often, this is abbreviated to "head".
Head refs are stored in `$GIT_DIR/refs/heads/`.
revision::
A particular state of files and directories which was stored in
the object database. It is referenced by a commit object.
----
It is just me or the glossary entry for `branch` is unnecessary
complicated?
Let's take a look at other definitions:
In software engineering, 'branch' is a separate line of development, which
among others allows development on a project to diverge in two directions,
such as a stable and a development version. (WikiPedia:Branch)
In the CVS team development environment, a separate line of development
where changes can be isolated. When a programmer changes files on
a branch, those changes do not appear on the main trunk
or other branches. (cvs.info)
So from the user's point of view, 'branch' is simply _named line of
development_. Refer to topic and tracking branches.
>From the point of view of commit, current branch (or rather branch
head/branch tip) is the place where we attach current development line
(current commit has current head as parent, and head is advanced to the
current commit), something akin to 'top' pointer for stack implemented as
linked list.
ONLY from the point of view of HISTORY, branch define "non-cyclical graph of
revisions, i.e. the complete history of a particular revision, which is
called the branch head." Merges somewhat obscure the branches (as history),
unless for example we assume that first parent is on the same branch, or
use note header to mark appropriate parent/commit. Also git does not record
where branch started... New branch commit logging proposal, and per-branch
configuration should help with these issues.
No concrete proposal for git glossary update...
--
Jakub Narebski
Warsaw, Poland
next reply other threads:[~2006-05-17 11:37 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-05-17 11:37 Jakub Narebski [this message]
2006-05-17 18:28 ` [RFD] Git glossary: 'branch' and 'head' description Junio C Hamano
2006-05-17 19:13 ` Jakub Narebski
2006-05-17 19:57 ` Junio C Hamano
2006-05-17 20:06 ` Jakub Narebski
2006-05-19 6:53 ` David Kågedal
2006-05-19 9:21 ` Shawn Pearce
2006-05-20 0:28 ` Daniel Barkalow
2006-05-20 0:35 ` Junio C Hamano
2006-05-20 1:36 ` Daniel Barkalow
2006-05-20 2:06 ` Linus Torvalds
2006-05-21 1:01 ` Shawn Pearce
2006-05-21 8:30 ` Jakub Narebski
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='e4f1ta$e07$1@sea.gmane.org' \
--to=jnareb@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 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).