From: Paul Eggert Date: Mon, 6 Sep 2004 01:03:20 +0000 (+0000) Subject: (String tests): Improve quality of warning about X-Git-Tag: v5.3.0~739 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac161f59f7a20b245107d0ccd0fc570943871f3d;p=thirdparty%2Fcoreutils.git (String tests): Improve quality of warning about quoting strings for the shell. --- diff --git a/doc/coreutils.texi b/doc/coreutils.texi index 531298d260..7033d15a88 100644 --- a/doc/coreutils.texi +++ b/doc/coreutils.texi @@ -9553,9 +9553,15 @@ numbers, i.e., if they are hard links to each other. @cindex string tests -These options test string characteristics. Strings are not quoted for -@command{test}, though you may need to quote them to protect characters -with special meaning to the shell, e.g., spaces. +These options test string characteristics. You may need to quote +@var{string} arguments for the shell. For example: + +@example +test -n "$V" +@end example + +The quotes here prevent the wrong arguments from being passed to +@command{test} if @samp{$V} is empty or contains special characters. @table @samp