summaryrefslogtreecommitdiffstats
path: root/usr.bin/lockf/lockf.1
diff options
context:
space:
mode:
authorjdp <jdp@FreeBSD.org>1998-07-08 05:29:05 +0000
committerjdp <jdp@FreeBSD.org>1998-07-08 05:29:05 +0000
commit2756040b8bf0afb2cb87ce31b2b0dfafc62d20c9 (patch)
treec50aab11f319c9823911201baa9007001bacb793 /usr.bin/lockf/lockf.1
parent397a367a3ecff8cf99508842bcd945095408dd52 (diff)
downloadFreeBSD-src-2756040b8bf0afb2cb87ce31b2b0dfafc62d20c9.zip
FreeBSD-src-2756040b8bf0afb2cb87ce31b2b0dfafc62d20c9.tar.gz
Add a "-k" option, to specify that the lock file should be kept
rather than removed. Submitted by: Nick Barnes <Nick.Barnes@pobox.com>
Diffstat (limited to 'usr.bin/lockf/lockf.1')
-rw-r--r--usr.bin/lockf/lockf.119
1 files changed, 12 insertions, 7 deletions
diff --git a/usr.bin/lockf/lockf.1 b/usr.bin/lockf/lockf.1
index 4ce28cb..36b50de 100644
--- a/usr.bin/lockf/lockf.1
+++ b/usr.bin/lockf/lockf.1
@@ -1,5 +1,5 @@
.\"
-.\" Copyright (C) 1997 John D. Polstra. All rights reserved.
+.\" Copyright (C) 1998 John D. Polstra. All rights reserved.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
@@ -22,9 +22,9 @@
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
.\" SUCH DAMAGE.
.\"
-.\" $Id: lockf.1,v 1.4 1997/02/22 19:55:53 peter Exp $
+.\" $Id: lockf.1,v 1.5 1998/03/23 07:44:28 charnier Exp $
.\"
-.Dd January 8, 1997
+.Dd July 7, 1998
.Os FreeBSD
.Dt LOCKF 1
.Sh NAME
@@ -32,7 +32,7 @@
.Nd execute a command while holding a file lock
.Sh SYNOPSIS
.Nm
-.Op Fl s
+.Op Fl ks
.Op Fl t Ar seconds
.Ar file
.Ar command
@@ -51,9 +51,11 @@ After the
.Ar command
completes,
.Nm
-releases the lock and removes the
-.Ar file .
-BSD-style locking is used, as described in
+releases the lock, and removes the
+.Ar file
+unless the
+.Fl k
+option is specified. BSD-style locking is used, as described in
.Xr flock 2 ;
the mere existence of the
.Ar file
@@ -61,6 +63,9 @@ is not considered to constitute a lock.
.Pp
The following options are supported:
.Bl -tag -width Fl
+.It Fl k
+Causes the lock file to be kept (not removed) after the command
+completes.
.It Fl s
Causes
.Nm
OpenPOWER on IntegriCloud