git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: Martin Waitz <tali@admingilde.org>
Cc: Josef Weidendorfer <Josef.Weidendorfer@gmx.de>,
	git@vger.kernel.org, Junio C Hamano <junkio@cox.net>
Subject: Re: Subprojects tasks
Date: Sun, 17 Dec 2006 14:01:09 +0100	[thread overview]
Message-ID: <200612171401.10585.jnareb@gmail.com> (raw)
In-Reply-To: <20061217114546.GG12411@admingilde.org>

Martin Waitz wrote:
> On Sun, Dec 17, 2006 at 01:01:09AM +0100, Josef Weidendorfer wrote:

>> IMHO it simply is added flexibility to allow a checkout to be separate from
>> the .git/ directory, same as explicitly setting $GIT_DIR would do.
>> So this .gitlink file is on the one hand one kind of convenience for users
>> which want to keep their repository separate, yet do not want to specify
>> $GIT_DIR all the time in front of git commands.
>> The .gitlink file simply makes the linkage to the separate repository
>> persistent.
> 
> I can see the reason for wanting to use another object database,
> but HEAD and index should always be stored together with the
> checked out directory.  So perhaps we just need some smart way to
> search for the object database, but keep the .git directory.

Well, in the .gitlink proposal you could specify GIT_DIR for checkout,
or separately: GIT_OBJECT_DIRECTORY, GIT_INDEX_FILE, GIT_REFS_DIRECTORY
(does not exist yet), GIT_HEAD_FILE (does not exist yet, and I suppose
it wouldn't be easy to implement it). By the way, that's why I'm for
.gitlink name for the file, not .git -- this way .gitlink can "shadow"
what's in .git, for example specifying in a smart way where to search
(where to find) object database, but HEAD and index would be stored
together with the checked out directory in .git

By the way, I'm rather partial to supermodule following HEAD in submodule,
not specified branch. First, I think it is easier from implementation
point of view: you don't have to remember which branch supermodule should
take submodule commits from; and this cannot be fixed branch name like
'master'. For example 'maint' branch of supermodule could track 'maint'
branch of submodule, 'master' branch of supermodule track 'master'
branch of submodule, 'next' branch of supermodule tranck 'master' (!)
branch of submodule, 'pu' branch of supermodule track 'next' (!) branch
of submodule. 

Second, if you want to do some independent work on the module not related
to work on submodule you should really clone (clone -l -s) submodule
and work in separate checkout; the complaint that with tracking HEAD
you can check-in wrong version of submodule to supermodule commit
doesn't hold, because you still would have problem that _tree_
of supermodule would have wrong version of submodule. And moving to
using single defined branch of submodule brings multitude of other
problems: for example you might usually track 'master' version of
submodule, but for a short time need to track 'next' branch because
it has functionality you need; and another time you need to move
to 'maint' branch or even your own branch because 'master' version
breaks something in supermodule.

Hmmm... I wonder how planned allowing to checking out tags, non-head
branches (e.g. tracking/remote branches) and arbitrary commits but
forbidding committing when HEAD is not a refs/heads/ branch would
affect submodules / subprojects...

-- 
Jakub Narebski

  reply	other threads:[~2006-12-17 12:58 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-16 18:32 Subprojects tasks Junio C Hamano
2006-12-16 18:45 ` Jakub Narebski
2006-12-16 23:01   ` Martin Waitz
2006-12-16 23:15     ` Jakub Narebski
2006-12-17  0:01       ` Josef Weidendorfer
2006-12-17 11:45         ` Martin Waitz
2006-12-17 13:01           ` Jakub Narebski [this message]
2006-12-17 13:48             ` Martin Waitz
2006-12-17 14:29               ` Jakub Narebski
2006-12-17 19:54                 ` Martin Waitz
2006-12-17 23:27                   ` Josef Weidendorfer
2006-12-18  7:45                     ` Martin Waitz
2006-12-17 23:23               ` Josef Weidendorfer
2006-12-18  7:44                 ` Martin Waitz
2006-12-18 10:30                   ` Josef Weidendorfer
2006-12-17  0:08       ` Josef Weidendorfer
2006-12-16 20:35 ` Sven Verdoolaege
2006-12-16 21:07   ` Junio C Hamano
2006-12-16 22:58     ` Martin Waitz
2006-12-16 23:14       ` Sven Verdoolaege
2006-12-17  0:32       ` Josef Weidendorfer
2006-12-17  8:48 ` Alan Chandler
2006-12-17 10:01   ` Jakub Narebski
2006-12-17 11:17 ` Martin Waitz

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=200612171401.10585.jnareb@gmail.com \
    --to=jnareb@gmail.com \
    --cc=Josef.Weidendorfer@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=junkio@cox.net \
    --cc=tali@admingilde.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.
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).