From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1886 invoked from network); 24 Jul 2006 11:24:14 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,FORGED_RCVD_HELO autolearn=ham version=3.1.3 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 24 Jul 2006 11:24:14 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 12123 invoked from network); 24 Jul 2006 11:24:07 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 24 Jul 2006 11:24:07 -0000 Received: (qmail 5844 invoked by alias); 24 Jul 2006 11:23:58 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10544 Received: (qmail 5834 invoked from network); 24 Jul 2006 11:23:58 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 24 Jul 2006 11:23:58 -0000 Received: (qmail 10834 invoked from network); 24 Jul 2006 11:23:58 -0000 Received: from py-out-1112.google.com (64.233.166.177) by a.mx.sunsite.dk with SMTP; 24 Jul 2006 11:23:56 -0000 Received: by py-out-1112.google.com with SMTP id z74so2011180pyg for ; Mon, 24 Jul 2006 04:23:22 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=ht0mj28s6FyN0DH7k6WUPpFDzpl7lkoEyK2wUUM9oNFXwP49jsGsduir093/ezN5h1PwEBVHNbc1dxSCoRieZKAtS+6SByWTTqkhsXl+k6NvyAetISH9OdFItxvycLgEV0AnLPBzJic0FKvkvbh9MFn/FSbhiFv8slSKi4vXvuQ= Received: by 10.35.37.13 with SMTP id p13mr7417936pyj; Mon, 24 Jul 2006 04:23:21 -0700 (PDT) Received: by 10.35.132.20 with HTTP; Mon, 24 Jul 2006 04:23:21 -0700 (PDT) Message-ID: <96c45c490607240423u131caf80w6e5d667c735a65b9@mail.gmail.com> Date: Mon, 24 Jul 2006 21:23:21 +1000 From: Sean To: "Peter Stephenson" Subject: Re: Does zsh have an equivalent to the shopt command ? Cc: zsh-users@sunsite.dk In-Reply-To: <200607241001.k6OA1rvM003764@news01.csr.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <96c45c490607220357h2c841b20q506de061f0e6f43b@mail.gmail.com> <200607221508.k6MF8W0w002651@pwslaptop.csr.com> <96c45c490607240044t282314dcn149e04073c0c2a1f@mail.gmail.com> <200607241001.k6OA1rvM003764@news01.csr.com> The message fails to print and the shell hangs ! On 7/24/06, Peter Stephenson wrote: > Sean wrote: > > On futher investigation, it appears that it is not actually choking on > > that line, rather this code which appears in many of the case option > > function calls: > > > > version() { sed -e 's/^ //' < > TODO.TXT Manager > > Version 1.6.3 > > Author: Gina Trapani (ginatrapani@gmail.com) > > Release date: 5/11/2006 > > Last updated: 7/6/2006 > > License: GPL, http://www.gnu.org/copyleft/gpl.html > > More information and mailing list at http://todotxt.com > > EndVersion > > exit 1 > > } > > Hmmm... again, that should work fine and does on my machine; the > shell isn't asked to do anything much beyond parsing a here document. > When you say "chokes", what do you mean? Obviously calling the > function will cause the shell to exit, because of the "exit 1" at the > end ; is it failing to print the message, exiting in some odd way, > hanging...? Or are you saying the options to the parent function (with > the getopts) are such that this function shouldn't be called? In which > case, what combination of options to that function is causing unexpected > behaviour? (I could believe getopts behaved differently from bash but I > need to see the command line being passed.) > > I'm guessing a lot of the spaces in that function were actually > tabs, but I've put those back and not had any problem. > > -- > Peter Stephenson Software Engineer > CSR PLC, Churchill House, Cambridge Business Park, Cowley Road > Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070 > > > To access the latest news from CSR copy this link into a web browser: http://www.csr.com/email_sig.php >