Commit Graph

33 Commits

Author SHA1 Message Date
wiz 14b00a757c Remove unnecessary Tn. 2017-10-18 18:11:54 +00:00
kre 9bbf3fccba I have seen (way too often) uses of test(1) that are not defined to
actually work (but just happen to, today, and in some cases, even
that trusts to some luck.)

It has been recently pointed out to me that the man page (ie: this
file) doesn't give any real guidance to what is really acceptable,
and what is not.

The CAVEATS section does note that the grammar is ambiguous, but then
just says that test(1) implements what POSIX requires, and refers
readers to the relevant section of the POSIX standard for more details.
That is probably asking too much of the average reader...

So, add some extra information in the CAVEATS with what is defined to work,
and what should be avoided.   Not all of the POSIX rules are here, but this
might hopefully help script authors avoid some of the pitfalls.
2017-10-18 08:54:59 +00:00
wiz 01869ca4d2 Remove workaround for ancient HTML generation code. 2017-07-03 21:28:48 +00:00
sevan 7346e185f5 Document the version test first appeared.
Bump date.
2016-08-12 03:17:41 +00:00
dholland 4142c9b7ca usage nit 2016-05-27 05:50:07 +00:00
wiz dbb168824f - Remove unneeded consecutive argument in `.Nm' macros;
- rename `GRAMMAR AMBIGUITY' section to `CAVEATS', and move it to
  correct location;
- bump date.

From Bug Hunting.
2012-12-16 17:57:49 +00:00
wiz 193ee60c7d Correct usage for parentheses, and mark up "expression" in more places.
From Bug Hunting in PR 42286.
2009-11-10 18:19:46 +00:00
wiz fc61954d0b Remove leading zero in Dd argument. 2009-05-06 08:26:43 +00:00
jschauma 3ebf4f45cb Note that all file tests with the exception of -h and -L follow symbolic
links and thus evaluate the test for the file pointed at.
2009-05-05 19:04:01 +00:00
joerg 0feb17a4b1 Fix markup. 2009-04-12 13:52:20 +00:00
uwe 8e85c1baf1 Use the same wording for '-p' as for other file related tests. 2007-05-15 22:00:51 +00:00
hubertf 7eef11b485 Revert previous (==) - not worth the trouble. 2006-09-24 13:24:08 +00:00
wiz dff6308718 Bump date for previous. 2006-09-23 11:22:10 +00:00
hubertf f9278bfbec Allow '==' as synonym to '=', just like our ksh and bash do.
This also affects the sh(1) builtin test command.
2006-09-22 22:15:24 +00:00
agc b5b2954259 Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22249, verified by myself.
2003-08-07 09:05:01 +00:00
wiz 14dfaa4b03 New policy: New sentences start on a new line.
Patches by Robert Elz <kre at munnari oz au>, with minimal changes by me.
2002-09-25 15:18:36 +00:00
ross dc5571b22e Generate <>& symbolically. I'm avoiding .../dist/... directories for now. 2002-02-08 01:21:55 +00:00
wiz 3ebcdc5e43 Whitespace nits. 2001-12-20 19:31:48 +00:00
wiz 4b238d257d Properly quote `[' as macro argument. 2001-10-17 21:14:45 +00:00
kleink 2caf6aacdd For commands and utilities, use EXIT STATUS rather than RETURN VALUES as
appropriate (and documented in mdoc(7)).
2000-09-04 07:30:07 +00:00
abs 98b54453f0 Remove duplicate 'string' / 's1' entry 1999-12-17 13:16:44 +00:00
kleink 900ca60345 Reverse the advice given to (now) prefer -h over -L; the former is defined in
1003.2bD3 and SVID4 and thus supposedly more portable.
1999-08-22 14:06:59 +00:00
garbled 1e1533cde9 the '[' wasn't being displayed properly as a command. Thanks to Charles
for the fix.
1999-03-09 07:05:33 +00:00
mrg 6be07a674c add missing .Nm calls and MLINKS. from spz@serpens.swb.de 1997-11-12 00:47:32 +00:00
mycroft c04eacd743 Fix format of description line. 1997-10-09 07:37:09 +00:00
mikel a18d01ced0 add SYNOPSIS line for [; fixes PR bin/3705 1997-06-05 06:39:59 +00:00
pk 3c7b56e9b2 Note compatibility `-h' op. (from Rob Windsor; PR#1740) 1996-01-05 12:39:30 +00:00
cgd a86f3aeda3 clean up Id's, and such. reorganize man page slight to match lite's org. 1995-03-21 07:03:50 +00:00
jtc 008c3a98a0 Replaced test with simpler, more feature rich, version derived from pdksh. 1994-06-30 05:12:29 +00:00
jtc 61c805aef5 The file_descriptor argument to the -t primary is no longer optional. 1994-06-29 22:26:50 +00:00
cgd cc288c2f3b add support for 'test -h' a la SunOS 1994-02-19 06:28:59 +00:00
mycroft b1bd4afedc Add RCS indentifiers. 1993-08-01 07:42:49 +00:00
glass e5ac8e1e2a new 'test' from ftp.uu.net:/systems/unix/bsd-sources, got rid of GNU thing 1993-04-26 23:30:42 +00:00