+1

Files: allow to (re)initialize several missing submodules at once

Bugged 1 year ago updated by Patrick Lehmann 8 months ago 2

Sometimes, you have your working tree submodules on this state:

And SmartGit allows you to hit the `Initialize` button. But, if you select more than 1 submodule deleted/uninitialized, SmarGit hides the option:

Forcing me to do one by one. 

SmartGit could be smarter and do not hide the `Initialize` option when selecting several uninitialized submodules.

Related to:

  1. https://smartgit.userecho.com/communities/1/topics/573-submodules-reset-multiple-submodules-at-once

In general, Initialize may bring a dialog, e.g. to change the submodule's URL in which case it doesn't make sense to handle multiple submodules at once. But for the illustrated case of broken/missing submodules, it should be possible to (re)initialize multiple submodules at once.

The uninitialized submodule state is also cause if the submodule has again submodules. While the parent submodule gets added, fetches and checked out. the child submodules are uninitialized.

To minimize this situation, a "sub module add" could be recursive. Add a checkbos for recursive submodule inits.