summaryrefslogtreecommitdiffstats
path: root/core/includes
diff options
context:
space:
mode:
authorSimon Rettberg2021-07-09 14:49:21 +0200
committerSimon Rettberg2021-07-09 14:49:21 +0200
commit95af82bfdb2413f8f1851972f2819e47d19f1bc2 (patch)
treea8c2dbd5b9411e0b5dc9afe185d1d7b2263fd9a2 /core/includes
parentRemove activate_qt helper (diff)
downloadmltk-95af82bfdb2413f8f1851972f2819e47d19f1bc2.tar.gz
mltk-95af82bfdb2413f8f1851972f2819e47d19f1bc2.tar.xz
mltk-95af82bfdb2413f8f1851972f2819e47d19f1bc2.zip
Store cloned repo information in target system
Diffstat (limited to 'core/includes')
-rw-r--r--core/includes/downloader.inc5
1 files changed, 2 insertions, 3 deletions
diff --git a/core/includes/downloader.inc b/core/includes/downloader.inc
index 7de0945d..f280c8ef 100644
--- a/core/includes/downloader.inc
+++ b/core/includes/downloader.inc
@@ -142,11 +142,10 @@ autoclone () {
else
git clone "$url" "$dstdir/$dst" || perror "Could not clone $url"
if [ -n "$checkout" ]; then
- cd "$dstdir/$dst" || perror "cd error. check redbook."
- git checkout "$checkout" || perror "Could not checkout $checkout from $url"
- cd -
+ git -C "$dstdir/$dst" checkout "$checkout" || perror "Could not checkout $checkout from $url"
fi
fi
+ [ -n "$AUTOCLONE_FILE" ] && echo "$( git rev-parse --abbrev-ref HEAD ) $( git rev-parse --short HEAD )" >> "$AUTOCLONE_FILE"
done
return 0
}