On Sun, 26 Jun 2011 23:39:08 -0700 (PDT)
Thorsten Peters <impyna...@googlemail.com> wrote:
> i need a checkout of a branch with different custom folders for each
> i test "submodules" and think that this is not the correct way for my
> (i want to commit and update the custom folder)
> What about this:
> I checkout a branch and add "custom" to .gitignore.
> Then i checkout "custom" out of an other repository.
> So i have a branch of repository 1 in a branch of repository 2.
> Now i can commit and push each branch.
> What you think about this idea?
I'm not sure I have parsed this correctly, but in general you can't
have a directory from one repository to be checked out into a work tree
pertaining to another repository. This is not Subversion where you can
freely check out components from arbitrary URIs. This is mostly
because object which Git manages do not have URIs of any sort attached
You can go another way instead:
1) Check out the repository containing your "custom" directories
somewhere, let's say, into ~/devel/custom-repo.
2) Check out another repository to *another* directory,
let's say, into ~/devel/main-repo.
3) Now symlink the necessary directories from custom-repo under the
directory containing the main repo's work tree,
something like this:
$ ln -s ~/devel/custom-repo/custom ~/devel/main-repo/
Now you have the "custom" directory appeared in the main-repo's
4) Add these symlinks to .gitignore of the main-repo.
You received this message because you are subscribed to the Google Groups "Git
for human beings" group.
To post to this group, send email to firstname.lastname@example.org.
To unsubscribe from this group, send email to
For more options, visit this group at