summaryrefslogtreecommitdiff
path: root/plugins/repo/get.d.sh
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/repo/get.d.sh')
-rw-r--r--plugins/repo/get.d.sh10
1 files changed, 7 insertions, 3 deletions
diff --git a/plugins/repo/get.d.sh b/plugins/repo/get.d.sh
index 9ef25b9..9b1b5bc 100644
--- a/plugins/repo/get.d.sh
+++ b/plugins/repo/get.d.sh
@@ -16,9 +16,13 @@ id="$1"
dir="$2"
tmp=`tempfile`
-"$RVSDIR/get.f" `sed -n 's/^hash://p' "$db"` "$tmp"
+"$RVSDIR/get.f" "$id" "$tmp"
-mkdir "$dir"
+#install -d "$dir"
+mkdir -p "$dir"
+
+cd "$dir"
+rm -rf ./*
while read line; do
# GNU bash optimized version
#hash=${line/#*:/}
@@ -26,7 +30,7 @@ while read line; do
# POSIX version
hash=`echo "$line" | sed 's/^.*://'`
name=`echo "$line" | sed "s/:$hash$//"`
- "$RVSDIR/get" "$dir/$file"
+ "$RVSDIR/get" "$hash" "$name"
done < "$tmp"
rm "$tmp"