Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Baumann <mail@andreasbaumann.cc>2023-06-12 12:26:20 +0200
committerAndreas Baumann <mail@andreasbaumann.cc>2023-06-12 12:26:20 +0200
commitb7e2e1ec6f66af9619037f81122d6ee790c7de10 (patch)
tree884d64bd98d84d7e83ab3af537ce9ebfa5ac127d
parent0326d81e58ec48c3ed7be7a88cad6436c06860d5 (diff)
build-packages: added a -e parameter for endless self-execution
-rwxr-xr-xbin/build-packages12
1 files changed, 12 insertions, 0 deletions
diff --git a/bin/build-packages b/bin/build-packages
index 7a5a541..12821f0 100755
--- a/bin/build-packages
+++ b/bin/build-packages
@@ -62,6 +62,8 @@ usage() {
>&2 echo ' Cannot be combined with -l.'
>&2 echo ' -x: If package build fails, do not request new assignment(s).'
>&2 echo ' Cannot be combined with -l.'
+ >&2 echo ' -e: Run in an endless loop (careful, not all processes might get killed'
+ >&2 echo ' after every finished run!).'
>&2 echo ''
>&2 echo 'known straws (separated by and enclosed in ":", sets of straws separated by " "):'
>&2 echo ' :clean_chroot:'
@@ -99,6 +101,7 @@ unset forced_package
unset forced_straws
unset prefered_package
exit_after_failure=false
+endless=false
timeout=0
while true
@@ -140,6 +143,9 @@ do
-x)
exit_after_failure=true
;;
+ -e)
+ endless=true
+ ;;
--)
shift
break
@@ -1131,3 +1137,9 @@ if ! ${i_am_the_master}; then
fi
>&2 echo 'Done.'
+
+# simple endless loop
+if [ ${endless} ]; then
+ sleep 10
+ exec "$0" "$@"
+fi