From: Junio C Hamano Date: Tue, 10 May 2016 17:38:31 +0000 (-0700) Subject: Merge branch 'jk/submodule-c-credential' into js/http-custom-headers X-Git-Tag: v2.9.0-rc0~21^2~1 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8ab8d959c6bf2f111590a230c841c352b8cf6518;p=thirdparty%2Fgit.git Merge branch 'jk/submodule-c-credential' into js/http-custom-headers * jk/submodule-c-credential: submodule: stop sanitizing config options submodule: use prepare_submodule_repo_env consistently submodule--helper: move config-sanitizing to submodule.c submodule: export sanitized GIT_CONFIG_PARAMETERS t5550: break submodule config test into multiple sub-tests t5550: fix typo in $HTTPD_URL git_config_push_parameter: handle empty GIT_CONFIG_PARAMETERS git: submodule honor -c credential.* from command line quote: implement sq_quotef() submodule: fix segmentation fault in submodule--helper clone submodule: fix submodule--helper clone usage submodule: check argc count for git submodule--helper clone submodule: don't pass empty string arguments to submodule--helper clone --- 8ab8d959c6bf2f111590a230c841c352b8cf6518 diff --cc git-submodule.sh index 43c68deee9,b1c056c715..b9469e7db6 --- a/git-submodule.sh +++ b/git-submodule.sh @@@ -591,24 -602,6 +602,24 @@@ cmd_deinit( done } +is_tip_reachable () ( - clear_local_git_env ++ sanitize_submodule_env && + cd "$1" && + rev=$(git rev-list -n 1 "$2" --not --all 2>/dev/null) && + test -z "$rev" +) + +fetch_in_submodule () ( - clear_local_git_env ++ sanitize_submodule_env && + cd "$1" && + case "$2" in + '') + git fetch ;; + *) + git fetch $(get_default_remote) "$2" ;; + esac +) + # # Update each submodule path to correct revision, using clone and checkout as needed #