From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29845 invoked from network); 13 Jul 2004 19:12:38 -0000 Received: from odin.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.85) by ns1.primenet.com.au with SMTP; 13 Jul 2004 19:12:38 -0000 Received: (qmail 18188 invoked from network); 13 Jul 2004 19:16:41 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 13 Jul 2004 19:16:41 -0000 Received: (qmail 2598 invoked by alias); 13 Jul 2004 18:29:12 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 7692 Received: (qmail 2589 invoked from network); 13 Jul 2004 18:29:11 -0000 Received: from odin.dotsrc.org (HELO a.mx.sunsite.dk) (qmailr@130.225.247.85) by sunsite.dk with SMTP; 13 Jul 2004 18:29:11 -0000 Received: (qmail 22002 invoked from network); 13 Jul 2004 18:33:19 -0000 Received: from dan.emsphone.com (@199.67.51.101) by a.mx.sunsite.dk with SMTP; 13 Jul 2004 18:33:05 -0000 Received: (from dan@localhost) by dan.emsphone.com (8.12.10/8.12.10) id i6DISR2C089112; Tue, 13 Jul 2004 13:28:27 -0500 (CDT) (envelope-from dan) Date: Tue, 13 Jul 2004 13:28:27 -0500 From: Dan Nelson To: Peter Whaite Cc: ZSH User List Subject: Re: Maildir empty? Message-ID: <20040713182827.GA8522@dan.emsphone.com> References: <20040712143306.GB2502@DervishD> <200407121804.i6CI4W3j005637@brains.moreideas.ca> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200407121804.i6CI4W3j005637@brains.moreideas.ca> X-OS: FreeBSD 5.2-CURRENT X-message-flag: Outlook Error User-Agent: Mutt/1.5.6i X-Spam-Checker-Version: SpamAssassin 2.63 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, hits=0.0 required=6.0 tests=none autolearn=no version=2.63 X-Spam-Hits: 0.0 In the last episode (Jul 12), Peter Whaite said: > DervishD wrote: > > > I can only give a partial answer. `[' is treated like any other > > > command, so its arguments are subject to filename expansion. > > It used to be that /bin/[ was a link to /bin/test, which is why > /bin/test still swallows a trailing ]. Now wasn't that clever! Getting off-topic :) but if your test eats a trailing bracket it's a bug. When test and [ are hardlinked, the program must check argv[0] and only eat a right-bracket if it was run as [. $ ls -la =test =\[ 814 -r-xr-xr-x 2 root wheel 93948 Nov 26 2003 /bin/[ 814 -r-xr-xr-x 2 root wheel 93948 Nov 26 2003 /bin/test $ command test "]" ; echo $? 0 $ command "[" "]" ; echo $? 1 SYNOPSIS test expression [ expression ] The test utility evaluates the expression and, if it evaluates to true, returns a zero (true) exit status; otherwise it returns 1 (false). If there is no expression, test also returns 1 (false). ... The following primaries are used to construct expression: ... _string_ True if _string_ is not the null string. -- Dan Nelson dnelson@allantgroup.com