summaryrefslogtreecommitdiff
path: root/usr.bin/timeout
diff options
context:
space:
mode:
authorKlemens Nanni <kn@cvs.openbsd.org>2022-12-22 19:53:25 +0000
committerKlemens Nanni <kn@cvs.openbsd.org>2022-12-22 19:53:25 +0000
commitdcd007097b9192d37a4b39e41094f0b07bfbe237 (patch)
tree5d14384480414cca7c4af172ac9a9dec1b03fdb2 /usr.bin/timeout
parent7cffd29be8ddc926f78306a722ae0466ca092588 (diff)
Denote multiple arguments with 'arg ...' not 'args'
A few programs used the plural in their synopsis which doesn't read as clear as the obvious triple-dot notation. mdoc(7) .Ar defaults to "file ..." if no arguments are given and consistent use of 'arg ...' matches that behaviour. Cleanup a few markups of the same argument so the text keeps reading naturally; omit unhelpful parts like 'if optional arguments are given, they are passed along' for tools like time(1) and timeout(1) that obviously execute commands with whatever arguments where given -- just like doas(1) which doesn't mention arguments in its DESCRIPTION in the first place. For expr(1) the difference between 'expressions' and 'expression ...' is crucial, as arguments must be passed as individual words. Feedback millert jmc schwarze deraadt OK jmc
Diffstat (limited to 'usr.bin/timeout')
-rw-r--r--usr.bin/timeout/timeout.110
-rw-r--r--usr.bin/timeout/timeout.c4
2 files changed, 6 insertions, 8 deletions
diff --git a/usr.bin/timeout/timeout.1 b/usr.bin/timeout/timeout.1
index 406dd0697cf..d2aab6b81b5 100644
--- a/usr.bin/timeout/timeout.1
+++ b/usr.bin/timeout/timeout.1
@@ -1,4 +1,4 @@
-.\" $OpenBSD: timeout.1,v 1.3 2021/09/04 11:58:31 schwarze Exp $
+.\" $OpenBSD: timeout.1,v 1.4 2022/12/22 19:53:23 kn Exp $
.\" $NetBSD: timeout.1,v 1.4 2016/10/13 06:22:26 dholland Exp $
.\"
.\" Copyright (c) 2014 Baptiste Daroussin <bapt@FreeBSD.org>
@@ -27,7 +27,7 @@
.\"
.\" $FreeBSD: head/usr.bin/timeout/timeout.1 268861 2014-07-18 22:56:59Z bapt $
.\"
-.Dd $Mdocdate: September 4 2021 $
+.Dd $Mdocdate: December 22 2022 $
.Dt TIMEOUT 1
.Os
.Sh NAME
@@ -41,14 +41,12 @@
.Op Fl -preserve-status
.Ar duration
.Ar command
-.Op Ar args
+.Op Ar arg ...
.Sh DESCRIPTION
The
.Nm
utility executes
-.Ar command ,
-with any
-.Ar args ,
+.Ar command
and kills it if it is still running after the
specified
.Ar duration .
diff --git a/usr.bin/timeout/timeout.c b/usr.bin/timeout/timeout.c
index f93d782f901..24d1c5520ee 100644
--- a/usr.bin/timeout/timeout.c
+++ b/usr.bin/timeout/timeout.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: timeout.c,v 1.21 2022/07/02 19:00:35 kn Exp $ */
+/* $OpenBSD: timeout.c,v 1.22 2022/12/22 19:53:23 kn Exp $ */
/*
* Copyright (c) 2021 Job Snijders <job@openbsd.org>
@@ -57,7 +57,7 @@ usage(void)
fprintf(stderr,
"usage: timeout [-k time] [-s sig] [--foreground]"
" [--preserve-status] duration\n"
- " command [args]\n");
+ " command [arg ...]\n");
exit(1);
}