1

Suppose I have this repository.

Now I want to clone only this module and not the whole repository. If you clone the whole repository I can get it, but I don't want that.

What is the best way to do that, or is it at all possible to do so?

Pritam Banerjee
  • 17,953
  • 10
  • 93
  • 108
  • 2
    Git isn't Subversion. Those aren't modules or sub-repos. The whole thing is one repo, and you have to clone the whole thing to get the bits you want. – cHao Jul 28 '16 at 05:01
  • @cHao So I will have to clone the whole repo? – Pritam Banerjee Jul 28 '16 at 05:02
  • Looks like it, unless they have another git repo containing just that bit. – cHao Jul 28 '16 at 05:03
  • @cHao Ok. Got it. Then I guess I will have to clone the entire repo. – Pritam Banerjee Jul 28 '16 at 05:05
  • 2
    Possible duplicate of [Is there any way to clone a git repository's sub-directory only?](http://stackoverflow.com/questions/600079/is-there-any-way-to-clone-a-git-repositorys-sub-directory-only) – Leon Jul 28 '16 at 08:40
  • See this answer: http://stackoverflow.com/a/28039894/6394138 – Leon Jul 28 '16 at 08:40
  • If you need not a repository, but a snapshot of a single module from it, then you can obtain it with `git archive` as described here: http://stackoverflow.com/a/25771130/6394138 – Leon Jul 28 '16 at 08:46

0 Answers0