Implement an early preview of submodule and package support

Resolvable submodules (aka. package management) is currently experimental
and is expected to contain bugs.  Do not use this functionality for any
real repositories as we expected to make breaking changes to this
functionality.