diff options
-rw-r--r-- | include/get.sh | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/include/get.sh b/include/get.sh index 0b0c7f71..959bdd6e 100644 --- a/include/get.sh +++ b/include/get.sh @@ -89,7 +89,16 @@ git_prep() x_ xbmkdir "${_loc%/*}" fi - x_ mv "$tmpgit" "$_loc" + if [ -z "$_loc" ]; then + # we only used git_prep to update caches, on + # a multi-tree project. tmpgit is useless now. + + x_ rm -Rf "$tmpgit" + else + # actual downloaded + + x_ mv "$tmpgit" "$_loc" + fi } fetch_submodule() |