14 ms·
Sorry, my poor English got in the way of comprehension; I thought 'sop' meant something else. As for why would I use submodules, we have a modular system from
by icebraining 10y ago
Sorry, my poor English got in the way of comprehension; I thought 'sop' meant something else.
As for why would I use submodules, we have a modular system from which different client packages are produced, and we need to manage the lifecycle of each module independently for each client.
- lmm 10y ago> we have a modular system from which different client packages are produced, and we need to manage the lifecycle of each module independently for each client. That makes sense, but sounds like you're not particularly making use of the submodule-to-emulate-big-repository functionality? (that is, each module has its own lifecycle, so there's no need to coordinate between updates to multiple modules for a different client). Indeed it seems like you couldn't accomplish this with a single big repository at all. (Personally I find submodules cumbersome as a way of managing a project in that setup (I'd rather just have releases of the modules, and then the per-client modules depend on releases), but if it's working for you then fair enough)
- WorldMaker 10y agoIs there a reason not to make use of your language's package management tools instead? In my experience, most such "submodules" are better off handled as packages (npm, NuGet, jspm, gem, et al) than submodules. Certainly there are complications for private/enterprise feeds, but most of the package managers have options these days (including pointing at just about any git repository directly).
- icebraining 10y agoThere are two constraints: we use Python and we run multiple copies of the software (with potentially version-incompatible modules) on the same host. That means we'd have to use virtualenv or similar, plus pip or easy_install to actually fetch and install the modules. On the developer side, it means having to manually update the dependencies file to upgrade a module, while with submodules they can just do "git pull" inside it and then "git add" in the parent repo, which auto-detects the new version. I'd love to see a simpler approach, but I couldn't find it.
- WorldMaker 10y agoAh, Python. Yeah, virtualenv + pip or docker + pip would probably be a better way to manage that sort of thing and increase separation of your git repositories (and better yet, better separation of your Python VMs), but I can see why submodules feel easier in this case if you are dealing with system global installs of Python packages right now.