diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2018-12-06 17:45:15 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2018-12-06 17:45:15 +0000 |
commit | 9d1f72911beff6dda6dd3a7aae57a8cea67ef095 (patch) | |
tree | ee875a4074659e5bde95321558eb2908d92fe898 /usr.bin/find | |
parent | 3c85e8dcb1160bed3f14051353f3c9eea562957e (diff) |
add -not as a sh friendly alias for !.
ok millert
Diffstat (limited to 'usr.bin/find')
-rw-r--r-- | usr.bin/find/find.1 | 10 | ||||
-rw-r--r-- | usr.bin/find/option.c | 3 |
2 files changed, 8 insertions, 5 deletions
diff --git a/usr.bin/find/find.1 b/usr.bin/find/find.1 index e773b56620f..a930b4edefc 100644 --- a/usr.bin/find/find.1 +++ b/usr.bin/find/find.1 @@ -1,4 +1,4 @@ -.\" $OpenBSD: find.1,v 1.95 2018/08/01 07:09:15 jmc Exp $ +.\" $OpenBSD: find.1,v 1.96 2018/12/06 17:45:14 tedu Exp $ .\" Copyright (c) 1990, 1993 .\" The Regents of the University of California. All rights reserved. .\" @@ -31,7 +31,7 @@ .\" .\" from: @(#)find.1 8.1 (Berkeley) 6/6/93 .\" -.Dd $Mdocdate: August 1 2018 $ +.Dd $Mdocdate: December 6 2018 $ .Dt FIND 1 .Os .Sh NAME @@ -524,6 +524,7 @@ This evaluates to true if the parenthesized expression evaluates to true. .Pp .It Cm \&! Ar expression +.It Cm -not Ar expression This is the unary NOT operator. It evaluates to true if the expression is false. .Pp @@ -624,9 +625,10 @@ primaries and .Ic -print0 , and operators -.Fl or -and .Fl and , +.Fl not , +and +.Fl or , are extensions to that specification. .Pp Historically, the diff --git a/usr.bin/find/option.c b/usr.bin/find/option.c index 49255b604f1..f897bc727b7 100644 --- a/usr.bin/find/option.c +++ b/usr.bin/find/option.c @@ -1,4 +1,4 @@ -/* $OpenBSD: option.c,v 1.20 2017/01/03 21:31:16 tedu Exp $ */ +/* $OpenBSD: option.c,v 1.21 2018/12/06 17:45:14 tedu Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -80,6 +80,7 @@ static OPTION options[] = { { "-name", N_NAME, c_name, O_ARGV }, { "-newer", N_NEWER, c_newer, O_ARGV }, { "-nogroup", N_NOGROUP, c_nogroup, O_ZERO }, + { "-not", N_NOT, c_not, O_ZERO }, { "-nouser", N_NOUSER, c_nouser, O_ZERO }, { "-o", N_OR, c_or, O_ZERO }, { "-ok", N_OK, c_exec, O_ARGVP }, |