summaryrefslogtreecommitdiff
path: root/bin/build-master-status
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2017-06-19 13:47:32 +0200
committerErich Eckner <git@eckner.net>2017-06-19 13:47:32 +0200
commite4677e04f39bfca06ca7b1fb92f89b7684f20e87 (patch)
tree8d6724ef0ee19e840d8e62df5c71ec70b1e9cd3e /bin/build-master-status
parent5e7e1ac0a4932156cfd399447968959f6081d3fe (diff)
downloadbuilder-e4677e04f39bfca06ca7b1fb92f89b7684f20e87.tar.xz
switch from sshfs to rsync - to avoid needing to remount
Diffstat (limited to 'bin/build-master-status')
-rwxr-xr-xbin/build-master-status27
1 files changed, 21 insertions, 6 deletions
diff --git a/bin/build-master-status b/bin/build-master-status
index 84e5dc6..ab052be 100755
--- a/bin/build-master-status
+++ b/bin/build-master-status
@@ -5,8 +5,13 @@
. "${0%/*}/../conf/default.conf"
stable="$(
- find "${master_mirror_directory}/i686/" \( -name '*testing' -o -name '*staging' \) -prune -o -name '*.pkg.tar.xz' -print 2> /dev/null | \
- wc -l
+ ${master_mirror_command} "${master_mirror_directory}/i686/" | \
+ awk '{print $5}' | \
+ grep -v 'testing$\|staging$\|^\.$' | \
+ while read -r dir; do
+ ${master_mirror_command} "${master_mirror_directory}/i686/${dir}/"
+ done | \
+ grep -c '\.pkg\.tar\.xz$'
)"
tasks="$(
wc -l < \
@@ -22,12 +27,22 @@ pending_packages="$(
wc -l
)"
staging="$(
- find "${master_mirror_directory}/i686/"*staging -name '*.pkg.tar.xz' 2> /dev/null | \
- wc -l
+ ${master_mirror_command} "${master_mirror_directory}/i686/" | \
+ awk '{print $5}' | \
+ grep 'staging$' | \
+ while read -r dir; do
+ ${master_mirror_command} "${master_mirror_directory}/i686/${dir}/"
+ done | \
+ grep -c '\.pkg\.tar\.xz$'
)"
testing="$(
- find "${master_mirror_directory}/i686/"*testing -name '*.pkg.tar.xz' 2> /dev/null | \
- wc -l
+ ${master_mirror_command} "${master_mirror_directory}/i686/" | \
+ awk '{print $5}' | \
+ grep 'testing$' | \
+ while read -r dir; do
+ ${master_mirror_command} "${master_mirror_directory}/i686/${dir}/"
+ done | \
+ grep -c '\.pkg\.tar\.xz$'
)"
broken="$(
ls "${work_dir}/package-states/" | \