Sunday 2 June 2013

Git submodules

When you clone a git repository with submodules, you should add the --recursive option.
git clone --recursive git://github.com/foo/bar.git
If you forget to do that during the cloning, you can update the submodules by
git submodule update --init
init adds the submodule repository URLs to .git/config, and update checks out a specific commit, rather than the tip of a branch.

No comments :

Post a Comment