summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2018-07-19 12:31:02 +0200
committerErich Eckner <git@eckner.net>2018-07-19 12:31:02 +0200
commit3ae2cff6f3f0febd73a4c3c3466e35ebedfa59db (patch)
tree606f84d3131490a0f50d1916278ceed033c83299 /bin
parent0f5133614a87624310c5471a0914bef8c1fdec63 (diff)
downloadbuilder-3ae2cff6f3f0febd73a4c3c3466e35ebedfa59db.tar.xz
bin/seed-build-list: remove -c|--cron-exit
Diffstat (limited to 'bin')
-rwxr-xr-xbin/seed-build-list43
1 files changed, 17 insertions, 26 deletions
diff --git a/bin/seed-build-list b/bin/seed-build-list
index 3505a53..fb47793 100755
--- a/bin/seed-build-list
+++ b/bin/seed-build-list
@@ -1,7 +1,5 @@
#!/bin/sh
-# seed the build list from differences between an x86_64 and our master mirror
-
# shellcheck disable=SC2119,SC2120
# shellcheck source=../lib/load-configuration
@@ -11,33 +9,31 @@
usage() {
>&2 echo ''
>&2 echo 'seed-build-list [options]:'
- >&2 echo ' seed the build list from'
- >&2 echo ' - differences between an x86_64 and our master mirror'
- >&2 echo ' - a list of packages which need to be rebuilt'
+ >&2 echo ' seed the build list from different sources'
>&2 echo ''
>&2 echo 'possible options:'
>&2 echo ' -a|--auto:'
>&2 echo ' Automatically reschedule packages which have run-time'
- >&2 echo ' dependencies that are not available from staging and'
- >&2 echo ' which cannot be replaced by another less stable version'
- >&2 echo ' of the same package.'
- >&2 echo ' -c|--cron-exit:'
- >&2 echo ' Exit with 0 if not getting a lock - makes the script'
- >&2 echo ' suitable for a crontab.'
+ >&2 echo ' dependencies that are not available from any real'
+ >&2 echo ' repository and which cannot be replaced by another,'
+ >&2 echo ' less stable version of the same package.'
>&2 echo ' -h|--help:'
>&2 echo ' Show this help and exit.'
- >&2 echo ' -i|--ignore $package:'
- >&2 echo ' Do not update $package.'
+ >&2 echo ' -i|--ignore $pkgbase:'
+ >&2 echo ' Do not update the given package.'
>&2 echo ' -m|--mirror $url:'
- >&2 echo ' Get x86_64 packages from mirror at $url.'
+ >&2 echo ' Schedule all packages, that are newer on the given'
+ >&2 echo ' x86_64 mirror - except packages in'
+ >&2 echo ' conf/seed-ignore-packages.'
>&2 echo ' -n|--no-action:'
>&2 echo ' Do not actually update build-list, just print it.'
- >&2 echo ' -p|--package $pkg_regex:'
- >&2 echo ' Update packages matching $pkg_regex.'
+ >&2 echo ' -p|--package $pkgname_regex:'
+ >&2 echo ' Reschedule packages matching $pkgname_regex. Note, that'
+ >&2 echo ' these packages must be known to the database.'
>&2 echo ' -u|--undelete $url: '
>&2 echo ' Schedule all former deletion-list packages which do not'
- >&2 echo ' belong on the deletion-list anymore and which are'
- >&2 echo ' available on $url.'
+ >&2 echo ' belong on the deletion-list anymore (e.g. can be built)'
+ >&2 echo ' and which are available on the given x86_64 mirror.'
>&2 echo ' -w|--wait:'
>&2 echo ' Wait for lock if necessary.'
[ -z "$1" ] && exit 1 || exit "$1"
@@ -48,9 +44,8 @@ tmp_dir=$(mktemp -d 'tmp.seed-build-list.XXXXXXXXXX' --tmpdir)
trap "rm -rf --one-file-system '${tmp_dir:?}'" EXIT
eval set -- "$(
- getopt -o achi:m:np:u:w \
+ getopt -o ahi:m:np:u:w \
--long auto \
- --long cron-exit \
--long help \
--long ignore: \
--long mirror: \
@@ -70,7 +65,6 @@ touch "${tmp_dir}/undelete-mirrors"
auto=false
update=true
wait_for_lock='-n'
-lock_error=1
while true
do
@@ -78,9 +72,6 @@ do
-a|--auto)
auto=true
;;
- -c|--cron-exit)
- lock_error=0
- ;;
-h|--help)
usage 0
;;
@@ -139,13 +130,13 @@ if ${update}; then
exec 9> "${sanity_check_lock_file}"
if ! verbose_flock -s ${wait_for_lock} 9; then
>&2 echo 'Cannot get sanity-check lock.'
- exit ${lock_error}
+ exit 1
fi
exec 8> "${build_list_lock_file}"
if ! verbose_flock ${wait_for_lock} 8; then
>&2 echo 'Cannot get build-list lock.'
- exit ${lock_error}
+ exit 1
fi
fi