From caa260edd5b9b49f1f4c3d78022805ceee38a0e3 Mon Sep 17 00:00:00 2001 From: davidovski Date: Sat, 21 Jan 2023 14:40:30 +0000 Subject: Fix mirror layout and add keychain --- src/mirror.sh | 10 +++++++--- src/sync.sh | 6 +++--- 2 files changed, 10 insertions(+), 6 deletions(-) (limited to 'src') diff --git a/src/mirror.sh b/src/mirror.sh index 7a2a672..b2b7c80 100644 --- a/src/mirror.sh +++ b/src/mirror.sh @@ -18,12 +18,16 @@ create_deps_graph () { mirror () { local MIRROR_DIR=${SYSROOT}${1:-$MIRROR_DIR} - mkdir -p $MIRROR_DIR - create_deps_graph > $MIRROR_DIR/deps.graph + mkdir -p $MIRROR_DIR/repo + create_deps_graph > $MIRROR_DIR/repo/deps.graph + + mkdir -p $MIRROR_DIR/keychain + cp -r $KEYCHAIN_DIR/* $MIRROR_DIR/keychain/ local packages=$(list) - cd $MIRROR_DIR + cd $MIRROR_DIR/repo fetch $packages cd - + } diff --git a/src/sync.sh b/src/sync.sh index 0be6c83..9f3ba29 100755 --- a/src/sync.sh +++ b/src/sync.sh @@ -78,11 +78,12 @@ popularity_contest () { fi local list=$(ls -1 -d $PACKAGES_DIR/*) - local total=$(echo $list | wc -l) + set -- $list + local total=$# local completed=0 for package_dir in $list; do - contest $package_dir & + contest $package_dir completed=$((completed+1)) ${QUIET} || hbar -T "${LARGE_CIRCLE} contesting packages..." $completed $total done @@ -132,7 +133,6 @@ sync () { # index packages and dependencies ${QUIET} || hbar - ${QUIET} || hbar index_repo 1 & index_deps 0 & -- cgit v1.2.1