Git submodules are awesome
Recently, I've switched all of my personal repositories over to Git from Subversion. When working on personal projects in subversion, I've always included some base functionality (my own boilerplate, if you will). These include my Zend Framework Authentication wrapper and controller and Smarty template wrapper, as well as some simple configuration files that these modules rely on. I've always used svn externals for these but I have to say that the git submodule system is making me smile.
For my own future reference, he is how to use them:
Adding a submodule:
git submodule add user@host:~/path/to/git/repo.git path/to/check/out
git submodule init
This will add and then initialize the repository under your current project. If the path doesn't exist, it will create it.
Updating a submodule:
The following will update the submodules under your current project.
git submodule update
If necessary, you can also go into the directory and perform the usual git tasks, since it is its own repository.
Have fun with git submodules!