diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2010-08-15 20:55:26 +0200 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2010-08-15 20:55:26 +0200 |
commit | b5fb2927cde513dc0fd82e4fd4dfe3836cf35728 (patch) | |
tree | a865bdac4e9bd0d273ca5a6aa4bc93ced9216557 /testing2x | |
parent | 583863043ad11eb203c479c9d0eea825a29ace39 (diff) | |
download | dbscripts-b5fb2927cde513dc0fd82e4fd4dfe3836cf35728.tar.gz dbscripts-b5fb2927cde513dc0fd82e4fd4dfe3836cf35728.tar.xz |
Lock repos before checking
Diffstat (limited to 'testing2x')
-rwxr-xr-x | testing2x | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -8,6 +8,13 @@ if [ $# -lt 1 ]; then exit 1 fi +# Lock everything to reduce possibility of interfering task between the different repo-updates +script_lock +for repo in 'core' 'extra' 'testing'; do + for pkgarch in ${ARCHES[@]}; do + repo_lock ${repo} ${pkgarch} || exit 1 + done +done declare -A pkgs @@ -39,8 +46,16 @@ for pkgbase in $*; do fi done +for pkgarch in ${ARCHES[@]}; do + repo_unlock 'testing' ${pkgarch} +done for repo in 'core' 'extra'; do + for pkgarch in ${ARCHES[@]}; do + repo_unlock ${repo} ${pkgarch} + done if [ -n "${pkgs[${repo}]}" ]; then "$(dirname $0)/db-move" 'testing' "${repo}" ${pkgs[${repo}]} fi done + +script_unlock |