login
Header Space

 
 

Re: [RFC] Submodules in GIT

Score:
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Torgil Svensson <torgil.svensson@...>
Cc: R. Steve McKown <rsmckown@...>, Linus Torvalds <torvalds@...>, <git@...>
Date: Friday, December 15, 2006 - 5:42 pm

On Friday 15 December 2006 18:43, Torgil Svensson wrote:

Ah, now I understand. I somehow missed this notation.


That all sounds fine, but how do you create such symlinks in practice?
Do you want to introduce special porcelain commands to create them?
Especially, what is the SCM user supposed to do to change the link
target, ie. from
 <commit>/path/to/subtree
to 
 <commit>/path2/to2/subtree2
?
Should this do a re-checkout at the other point?

By linking a file from a submodule, such a link seems to force that
this file has to be at a fixed position in the submodule. Otherwise,
some magic has to happen when the file is moved in the submodule,
possibly leading to a dangling link, eg. if the whole subdirectory
specified in the link is removed.

IMHO this is getting way to complex.
Much simpler is to include the full submodule at some path in
the supermodule, and create normal symlinks from the supermodule
into the submodule.

If you only want to check out part of a submodule, this should be
done with path-limiting checkouts, which should be a feature totally
independent from submodules.

And if you want to limit the number of objects transferred in cloning
of a subproject, it is better to further split this subproject into
multiple subprojects itself.
 

Of course, you need the submodule fully checked out somewhere in the
supermodule, and the link goes into the submodule directory. The
versioning is given by the supermodule/submodule link.


As already said: the link has to go into a submodule directory, which
will be checked out automatically with the clone of the supermodule.


The problem is not the representation in the git repository, but the
checked out module/submodule, where you need to use normal UNIX file semantics.
To move submodules around, the user should be able to just use
the normal UNIX "mv" commands, and git should be able to detect move
actions after the fact.
The simple thing here is that currently, git does not have this problem
as it tracks content, and does not even try to detect any moves at
commit time. This is different with submodules, as there, you want to
be able to track moves of any submodule root directories.

This now becomes a problem if you use symlinks to "unify" multiple checkouts
of the same submodule at multiple places in the supermodule, and move
the symlink around, as it easily can get dangling this way. Thus, you would
not have a way to see what submodule this link was talking about.

And for this thing, I do not see how your link object could help.

So it is better to use a simple submodule concept, and for this corner
cases, we perhaps could expect the user to fix e.g. a dangling symlink
to a previous submodule checkout himself, using a meaningful error message.


If you have a source commit chain A => B => C => D, you want
to make any build commits totally independent: you first only
are interested in a build commit for source versions A and D,
and later find out that a build commit for B and C would be nice,
too. If you force build commits into some history order, this
order now would be A => D => B => C, which makes no sense.

Build commit independence can easily be achieved by making every commit
parentless, without further history. You still have the link
to the source version via the submodule link in the tree.
But to not loose any such build commits, they have to appear
as tags or refs (unless integrated in another superproject
build commit).



The version coupling will be there if the whole submodule is available
at some path in the supermodule checkout, as said above.

Josef
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [RFC] Submodules in GIT, Jakub Narebski, (Tue Nov 28, 6:50 am)
Re: [RFC] Submodules in GIT, Andy Parkins, (Tue Nov 28, 9:35 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Wed Nov 29, 12:03 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Wed Nov 29, 4:00 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Thu Nov 30, 1:06 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Fri Dec 1, 5:02 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 7:00 am)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 8:09 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 8:12 am)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 9:05 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 9:35 am)
Re: [RFC] Submodules in GIT, Stephan Feder, (Fri Dec 1, 9:51 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 10:58 am)
Re: [RFC] Submodules in GIT, Stephan Feder, (Fri Dec 1, 11:47 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 12:54 pm)
Re: [RFC] Submodules in GIT, Stephan Feder, (Fri Dec 1, 1:33 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Fri Dec 1, 3:17 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 3:38 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Fri Dec 1, 5:04 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 5:37 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Fri Dec 1, 5:54 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 6:08 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Sat Dec 2, 6:04 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:40 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Sat Dec 2, 9:50 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:43 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Sat Dec 2, 9:02 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 2:48 pm)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 7:34 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 3:46 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Fri Dec 1, 9:43 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 9:46 am)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Fri Dec 1, 10:52 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 11:00 am)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Fri Dec 1, 12:38 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 12:57 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Fri Dec 1, 2:08 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 2:51 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 12:49 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 1:14 pm)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 1:08 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 4:13 pm)
Re: [RFC] Submodules in GIT, Jon Loeliger, (Fri Dec 8, 2:29 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Tue Dec 12, 4:32 am)
Re: [RFC] Submodules in GIT, Sven Verdoolaege, (Fri Dec 8, 2:45 pm)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 6:35 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 6:06 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 6:26 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 6:55 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 7:30 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 8:14 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 8:33 pm)
Re: [RFC] Submodules in GIT, Michael K. Edwards, (Mon Dec 4, 2:56 pm)
Re: [RFC] Submodules in GIT, Sam Vilain, (Mon Dec 4, 9:31 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Sat Dec 2, 5:27 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 7:07 pm)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 6:41 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 7:09 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:12 pm)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 7:49 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Sat Dec 2, 2:57 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sat Dec 2, 3:41 pm)
Re: [RFC] Submodules in GIT, R. Steve McKown, (Sat Dec 9, 5:34 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Sun Dec 10, 7:47 am)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Thu Dec 14, 5:27 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Thu Dec 14, 7:07 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Fri Dec 15, 1:43 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 15, 5:42 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Fri Dec 15, 7:43 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Fri Dec 15, 9:13 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 15, 9:49 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 15, 10:12 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Sat Dec 16, 4:50 am)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Fri Dec 15, 9:20 pm)
Re: [RFC] Submodules in GIT, Daniel Barkalow, (Mon Dec 4, 10:33 pm)
Re: [RFC] Submodules in GIT, sf, (Tue Dec 5, 6:07 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Sun Dec 3, 3:33 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Sun Dec 3, 5:19 am)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sun Dec 3, 1:54 pm)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Mon Dec 4, 4:26 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Mon Dec 4, 4:41 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Tue Dec 5, 6:38 am)
Re: [RFC] Submodules in GIT, Torgil Svensson, (Mon Dec 4, 5:36 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Tue Dec 5, 6:42 am)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 7:36 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Fri Dec 1, 8:12 pm)
Re: [RFC] Submodules in GIT, Sven Verdoolaege, (Sun Dec 3, 6:16 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sun Dec 3, 6:32 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Mon Dec 4, 7:12 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:18 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sat Dec 2, 4:44 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sun Dec 3, 4:46 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sat Dec 2, 5:22 pm)
Thoughts about memory requirements in traversals [Was: Re: [..., Josef Weidendorfer, (Sat Dec 2, 10:07 pm)
Re: Thoughts about memory requirements in traversals [Was: R..., Josef Weidendorfer, (Sat Dec 2, 11:21 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 5:06 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sat Dec 2, 5:29 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Sat Dec 2, 7:32 am)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sat Dec 2, 3:52 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:21 pm)
Re: [RFC] Submodules in GIT, Linus Torvalds, (Sat Dec 2, 4:46 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:58 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Sat Dec 2, 9:11 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Sat Dec 2, 5:22 am)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 7:03 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 6:12 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 7:17 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sat Dec 2, 4:24 pm)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Sat Dec 2, 8:55 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Sun Dec 3, 2:29 am)
Re: [RFC] Submodules in GIT, Josef Weidendorfer, (Fri Dec 1, 6:26 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 6:40 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 4:30 pm)
Re: [RFC] Submodules in GIT, Alan Chandler, (Fri Dec 1, 7:23 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Fri Dec 1, 2:06 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Thu Nov 30, 2:57 pm)
Re: [RFC] Submodules in GIT, Uwe Kleine-Koenig, (Tue Dec 5, 5:01 am)
Re: [RFC] Submodules in GIT, Sven Verdoolaege, (Tue Dec 5, 12:00 pm)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Tue Dec 5, 6:33 am)
Re: [RFC] Submodules in GIT, Uwe Kleine-Koenig, (Tue Dec 5, 11:02 am)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Tue Dec 5, 11:30 am)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 8:03 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 8:11 am)
Re: [RFC] Submodules in GIT, sf, (Fri Dec 1, 9:21 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 9:43 am)
Re: [RFC] Submodules in GIT, Stephan Feder, (Fri Dec 1, 10:23 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 11:07 am)
Re: [RFC] Submodules in GIT, Stephan Feder, (Fri Dec 1, 12:04 pm)
Re: [RFC] Submodules in GIT, Martin Waitz, (Fri Dec 1, 12:15 pm)
Re: [RFC] Submodules in GIT, Andy Parkins, (Fri Dec 1, 4:49 am)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Fri Dec 1, 5:33 am)
Re: [RFC] Submodules in GIT, Andy Parkins, (Fri Dec 1, 6:38 am)
Re: [RFC] Submodules in GIT, Andreas Ericsson, (Thu Nov 30, 8:16 am)
Re: [RFC] Submodules in GIT, Andy Parkins, (Thu Nov 30, 8:40 am)
Re: [RFC] Submodules in GIT, Steven Grimm, (Tue Nov 28, 3:58 pm)
Re: [RFC] Submodules in GIT, Shawn Pearce, (Tue Nov 28, 5:02 pm)
Re: [RFC] Submodules in GIT, Shawn Pearce, (Tue Nov 28, 11:44 am)
Re: [RFC] Submodules in GIT, Andy Parkins, (Tue Nov 28, 12:29 pm)
Re: [RFC] Submodules in GIT, sf, (Thu Nov 30, 7:57 am)
Re: [RFC] Submodules in GIT, Martin Waitz, (Wed Nov 29, 12:15 pm)
Re: [RFC] Submodules in GIT, Jon Loeliger, (Tue Nov 28, 1:38 pm)
Re: [RFC] Submodules in GIT, Shawn Pearce, (Tue Nov 28, 12:36 pm)
speck-geostationary