Skip to content

Commit

Permalink
Fix parsing by sh (yadm-dev#299)
Browse files Browse the repository at this point in the history
  • Loading branch information
TheLocehiliosan committed Jan 7, 2021
1 parent afab29c commit b32025b
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion yadm
Original file line number Diff line number Diff line change
Expand Up @@ -1323,7 +1323,10 @@ function upgrade() {
# been cloned first and then added as a submodule.
"$GIT_PROGRAM" submodule absorbgitdirs

local submodule_status
submodule_status=$("$GIT_PROGRAM" -C "$YADM_WORK" submodule status)
while read -r sha submodule rest; do
[ "$submodule" == "" ] && continue
if [[ "$sha" = -* ]]; then
continue
fi
Expand All @@ -1334,7 +1337,7 @@ function upgrade() {
error_out "Unable to upgrade. Could not deinit submodule $submodule"
}
submodules+=("$submodule")
done < <("$GIT_PROGRAM" -C "$YADM_WORK" submodule status)
done <<< "$submodule_status"

assert_parent "$YADM_REPO"
mv "$LEGACY_REPO" "$YADM_REPO"
Expand Down

0 comments on commit b32025b

Please sign in to comment.