summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2024-08-26 09:50:09 -0300
committerEuAndreh <eu@euandre.org>2024-08-26 09:50:09 -0300
commitdc67f74e2df4b2e4d70bbe5032351f5baeb98471 (patch)
tree1dc46c3befc2fe2b0f120e7202ab5d83293f27ee /src
parentsrc/untill: Copy in untill(1) as is (diff)
downloadeut-dc67f74e2df4b2e4d70bbe5032351f5baeb98471.tar.gz
eut-dc67f74e2df4b2e4d70bbe5032351f5baeb98471.tar.xz
src/untill: Remove -h and --help
Diffstat (limited to 'src')
-rwxr-xr-xsrc/untill52
1 files changed, 0 insertions, 52 deletions
diff --git a/src/untill b/src/untill
index 9290cfe..34532de 100755
--- a/src/untill
+++ b/src/untill
@@ -5,56 +5,9 @@ usage() {
cat <<-'EOF'
Usage:
until [-m MAX] [-n SECONDS] COMMAND...
- until -h
EOF
}
-help() {
- cat <<-'EOF'
-
-
- Options:
- -n SECONDS the amount of seconds to sleep between
- attempts (default: 5)
- -m MAX the maximum number of attempts (default: unlimited)
- -h, --help show this message
-
- COMMAND the shell command to be executed
-
-
- Runs COMMAND until it eventually succeeds, trying atmost MAX
- times. Sleep SECONDS between attempts.
-
-
- Examples:
-
- Try flaky build until it succeeds:
-
- $ until guix home build home.scm
-
-
- Try atmost 10 timex to build until a new version is successfull,
- waiting 30 seconds between attempts:
-
- $ until -m 10 -n 30 -- x git pull AND make
- EOF
-}
-
-
-for flag in "$@"; do
- case "$flag" in
- (--)
- break
- ;;
- (--help)
- usage
- help
- exit
- ;;
- (*)
- ;;
- esac
-done
_SECONDS=5
while getopts 'm:n:h' flag; do
@@ -65,11 +18,6 @@ while getopts 'm:n:h' flag; do
(n)
_SECONDS="$OPTARG"
;;
- (h)
- usage
- help
- exit
- ;;
(*)
usage >&2
exit 2