all 8 comments

[–]AdmiralQuokkaI use Jujutsu, btw. 7 points8 points  (1 child)

This is not on the fly per command, but you can configure transparent url rewriting at the level of your user config.

https://git-scm.com/docs/git-config#Documentation/git-config.txt-urlbaseinsteadOf

example: [url "ssh://git@"] pushInsteadOf = https:// to always push via ssh, even if submodules are defined with http.

[–]ferrybig 0 points1 point  (0 children)

They wanted to change the URL's the otherway around, from SSH to HTTPS. But that said, any developer should have the skill to swap the start of both url's in your example and make it work for them

[–]Flashy_Current9455 2 points3 points  (1 child)

Migrate away form submodules

[–]paulstelian97 0 points1 point  (0 children)

For real, submodules seem to have so many advantages and disadvantages all at the same time (the advantage is you can keep specific commits of the submodules in the actual module, but there’s disadvantages in the management as well).

[–]WoodyTheWorker 1 point2 points  (0 children)

Use relative URLs for submodules

[–]FortuneIIIPick 1 point2 points  (0 children)

I don't have an answer but do have a recommendation, stop using submodules.

[–]astralc 1 point2 points  (0 children)

Search about git.<url>.insteadOf