Git source needs a way to disable checking out submodules
Some git repositories have submodules in their .gitmodules, but don't actually intend for them to be checked out as part of the build. e.g. debian packages where the submodules exist as a developer convenience, while actual builds will extract tarballs to the appropriate place, instead.
Tarballs and appropriate git repos are not directly substitutable. (Tarballs will often have the necessary m4 macros pre-installed, for example).
I suggest the following:
- project.conf adds a field ("git-submodule-checkout" unless anyone objects to the naming scheme) which defaults to True, but can be set to false if you want the entire project to default to not checking out submodules.
- Git source plugin adds the config option ("submodule-checkout") that can override project-wide checking out of git submodules.
- Submodules specifically listed in the "submodules" field will be
checked-out even if
submodule-checkoutis False, so that a subset of the submodules in .gitmodules can be checked-out.
Also, could someone remind me why using variables for config options is discouraged? They would be very convenient for having project-wide defaults that can be overridden on a per-element level, but I can see no sign of anyone ever using them to decide something in-python.