Hi, sorry for not replying any more. I managed to lose track of this thread.
I'm afraid I still don't quite understand, although I didn't have quite the
time to read properly through your explanation.
There are still a lot of confusing terms in there that don't fit with my
typical "Git language", so let me try at another interpretation.
As it is often easier to solve a problem by first splitting it into several
smaller isolated problems, I'll exclude the fact that you want this in a
submodule. A submodule is just a link to a commit in another Git repository
in the end, so I'm not sure if that's a relevant factor for this question.
We can come back to it later anyhow.
*You want a repository clone that only has knowledge of a few branches.*
Does maybe this recipe  establish that kind of repository you want?
If this does not help you, could you perhaps try saying on a higher level
what you are actually trying to achieve without going into concrete Git
details? Perhaps someone has a better idea of an approach to suit your
On Monday, July 16, 2012 11:27:47 AM UTC+2, Nedvajz wrote:
> Do you understand what i mean? Is there any solution, or not?
> Thanks for reply;)
> On Friday, 29 June 2012 16:13:09 UTC+2, Nedvajz wrote:
>> is there a way, how to pull/clone (somehow) only commits of one, and only
>> one branch?
>> For example:
>> 1) Lets say i have 3 branches in one submodule. Master(commits 1,2,3,4) ,
>> Project1(commits 1,2,3,4,5) , Project2(commits 1,2,3,4,6,7,8).
>> 2) I am starting with Project3 and wanna to get submodule Master branch
>> only -> "git submodule add --only_specific_branch_commits
>> 3) Now i will look into submodule, and "git branch -v" will show me only
>> master, and as well "git branch -vr" show me only origin/master ...
>> And if i will try to git cherry-pick 5 on Master branch-> where 5 is
>> commit of Project1 only, there wont be any entry in history or so -> so it
>> Why I am looking for something like this?
>> We have cms for making Sites composed from submodules and via sumbodules
>> we can easily modificate what cms can/cant.
>> But always is there needed to specify one of plugins directly for that
>> project and there are changes useless for another projects.
>> So we made it till now via specific branch to get exactly what we need.
>> But after many and many projects, the repo of the most specified
>> plugins(modules) is going to be huge and it is not needed at all to get all
>> commits of all projects into new one, but just the clean master branch with
>> their commits.
>> Thanks for any help, Nedvajz.
You received this message because you are subscribed to the Google Groups "Git
for human beings" group.
To view this discussion on the web visit
To post to this group, send email to email@example.com.
To unsubscribe from this group, send email to
For more options, visit this group at