threads / discuss / 47152

`git commit -a` stages ignored submodules?

Subject: `git commit -a` stages ignored submodules?

## tl;dr

One message between Nov 10, 2017 and Nov 10, 2017.

replies: 0people: 1as markdown or json

Sergey Sharybin· Nov 10, 2017, 10:34 UTC · lore
Hello everyone,

There seems to be a difference how Git 2.15.0 handles submodules in comparison with 2.14.2.

In Git 2.14.2 `git commit -a` will not stage submodules which has `ignore = all` set in their .gitmodule section. However, in Git 2.15.0 `git commit -a` will stage all submodules no matter what their "ignore" setting is set to, and also no matter if submodule path is in .gitignore.

Didn't see anything explicit about this in release logs. Is it an expected new behavior?It is till possible to keep `git commit -a` to ignore submodules which are configured to be ignored?

-- 
With best regards, Sergey Sharybin

← back to recent threads