diff options
author | Jacob Keller <jacob.keller@gmail.com> | 2016-02-29 14:58:35 -0800 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2016-03-01 12:24:22 -0800 |
commit | 14111fc49272a70ceaeb5039796fbceb8a6e1cb7 (patch) | |
tree | 8f4a8499b97577d61dac31de1baca228a05915e4 /git-send-email.perl | |
parent | quote: implement sq_quotef() (diff) | |
download | tgif-14111fc49272a70ceaeb5039796fbceb8a6e1cb7.tar.xz |
git: submodule honor -c credential.* from command line
Due to the way that the git-submodule code works, it clears all local
git environment variables before entering submodules. This is normally
a good thing since we want to clear settings such as GIT_WORKTREE and
other variables which would affect the operation of submodule commands.
However, GIT_CONFIG_PARAMETERS is special, and we actually do want to
preserve these settings. However, we do not want to preserve all
configuration as many things should be left specific to the parent
project.
Add a git submodule--helper function, sanitize-config, which shall be
used to sanitize GIT_CONFIG_PARAMETERS, removing all key/value pairs
except a small subset that are known to be safe and necessary.
Replace all the calls to clear_local_git_env with a wrapped function
that filters GIT_CONFIG_PARAMETERS using the new helper and then
restores it to the filtered subset after clearing the rest of the
environment.
Signed-off-by: Jacob Keller <jacob.keller@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-send-email.perl')
0 files changed, 0 insertions, 0 deletions