While submodules may not be optimized for this usage, having a submodule of submodules can be a solution to maintaining a single point of access to multiple independent projects.
This has served needs such as those that arise when implementing a monorepo. Automating a superproject commit on every submodule update can alleviate a mostly administrative step when adopting such a setup.
I have pieced together a post-commit
hook that is fairly straightforward for automatically updating the superproject on every commit in a submodule.
#!/bin/bash
#
# Update a superproject when a commit is made to a submodule.
# Intended for .git/**modules/{THE_SUBMODULE}/hooks/post-commit
# where the double-star indicates variadic path elements.
#
# Depends on Git >= 2.13.
# Clean the Git environment before crossing repository boundaries.
# From https://stackoverflow.com/questions/36196548/cannot-trigger-post-commit-git-hook-on-git-submodule
while read variable; do
unset $variable
done < <(env | grep "^GIT_" | sed 's/=.*//g')
COMMIT_MSG="submodule update"
GIT="git"
SUPERPROJECT_WORKING_TREE=`git rev-parse --show-superproject-working-tree`
echo " Committing to $SUPERPROJECT_WORKING_TREE."
cd $SUPERPROJECT_WORKING_TREE
$GIT add .
$GIT commit -m "$COMMIT_MSG"