GitLab forks and submodules

Ben Gamari ben at
Mon Jan 7 15:32:36 UTC 2019

Moritz Angermann <moritz.angermann at> writes:

> Hi *,
> so what do we do with submodules? If you point someone to a fork of ghc, say:
Indeed submodules have been a constant thorn in our side. We encounter
this same issue during CI jobs on forks. To work around this we have a
script (.gitlab-ci/ which tweaks the submodule paths
to point to Others are free to use this
script locally however it is surely a hack.

I suppose we could just try changing the submodule upstream URLs to
absolute URLs. This would make the (arguably more common) case of
cloning and contributing without submodule changes easier, while making
the case of contributing patches with submodule changes more difficult.

My usual solution is to just clone from ghc/ghc and then add a separate
remote for my fork.


- Ben
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 487 bytes
Desc: not available
URL: <>

More information about the ghc-devs mailing list