Is there a global .gitconfig setting that allows to change the default of the ignore-submodules option from "all" to "dirty", "untracked", or "none"?
1 Answer
From git config:
diff.ignoreSubmodules is supposed to override any 'submodule.<name>.ignore' settings.
And it sets the default value of the --ignore-submodules command-line option.
However, Allan Jensen reports (in 2019, nine years later) that feature as not working, and proposes a patch, shown in this diff.
8 Comments
twig
How does that look in the config file? When I use "git config --global" it doesn't seem to write anything to my ~/.gitconfig file. Typing "git status" still shows submodules with -dirty at the end.
twig
hmm, seems like i've got it set up correctly but git status still shows dirty submodules. i type that on the project level by the way. do i need to do it on the submodule level also?
VonC
@twig: is there some
git submodule update missing, before querying any status?twig
Nope, they're all clean submodules. I just test by creating a new file or editing an existing file in a submodule (without committing) and it marks the submodule as dirty.
Allan Jensen
That does not appear to work. .gitmodules wins over .gitconfig settings, so only option at the moment is using the command-line
|