Skip to content

Commit

Permalink
submodule sync: use submodule--helper is-active
Browse files Browse the repository at this point in the history
Signed-off-by: Brandon Williams <bmwill@google.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
bmwill authored and gitster committed Mar 17, 2017
1 parent e7849a9 commit 25b31f1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions git-submodule.sh
Original file line number Diff line number Diff line change
Expand Up @@ -1089,14 +1089,14 @@ cmd_sync()
while read mode sha1 stage sm_path
do
die_if_unmatched "$mode" "$sha1"
name=$(git submodule--helper name "$sm_path")

# skip inactive submodules
if ! git config "submodule.$name.url" >/dev/null 2>/dev/null
if ! git submodule--helper is-active "$sm_path"
then
continue
fi

name=$(git submodule--helper name "$sm_path")
url=$(git config -f .gitmodules --get submodule."$name".url)

# Possibly a url relative to parent
Expand Down

0 comments on commit 25b31f1

Please sign in to comment.