From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15466 invoked from network); 7 Oct 2006 02:11:16 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.6 (2006-10-03) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00, FORGED_RCVD_HELO autolearn=ham version=3.1.6 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 7 Oct 2006 02:11:16 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 41246 invoked from network); 7 Oct 2006 02:11:10 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 7 Oct 2006 02:11:10 -0000 Received: (qmail 29153 invoked by alias); 7 Oct 2006 02:11:01 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10804 Received: (qmail 29140 invoked from network); 7 Oct 2006 02:11:00 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 7 Oct 2006 02:11:00 -0000 Received: (qmail 39968 invoked from network); 7 Oct 2006 02:11:00 -0000 Received: from vms040pub.verizon.net (206.46.252.40) by a.mx.sunsite.dk with SMTP; 7 Oct 2006 02:10:59 -0000 Received: from torch.brasslantern.com ([71.116.118.106]) by vms040.mailsrvcs.net (Sun Java System Messaging Server 6.2-4.02 (built Sep 9 2005)) with ESMTPA id <0J6Q007GLU1JH2AH@vms040.mailsrvcs.net> for zsh-users@sunsite.dk; Fri, 06 Oct 2006 21:10:32 -0500 (CDT) Received: from torch.brasslantern.com (localhost.localdomain [127.0.0.1]) by torch.brasslantern.com (8.13.1/8.13.1) with ESMTP id k972AUpW029342 for ; Fri, 06 Oct 2006 19:10:31 -0700 Received: (from schaefer@localhost) by torch.brasslantern.com (8.13.1/8.13.1/Submit) id k972AUA4029341 for zsh-users@sunsite.dk; Fri, 06 Oct 2006 19:10:30 -0700 Date: Fri, 06 Oct 2006 19:10:30 -0700 From: Bart Schaefer Subject: Re: ZLE widget to run gdb on command line In-reply-to: <20061006170408.GA3693@parhelion.globnix.org> To: zsh-users@sunsite.dk Message-id: <061006191030.ZM29340@torch.brasslantern.com> MIME-version: 1.0 X-Mailer: OpenZMail Classic (0.9.2 24April2005) Content-type: text/plain; charset=us-ascii References: <20061006145222.GA32307@namib.cs.utk.edu> <20061006170408.GA3693@parhelion.globnix.org> Comments: In reply to Phil Pennock "Re: ZLE widget to run gdb on command line" (Oct 6, 7:04pm) On Oct 6, 7:04pm, Phil Pennock wrote: } Subject: Re: ZLE widget to run gdb on command line } } On 2006-10-06 at 10:52 -0400, Chris Johnson wrote: } > print -s ${(z)BUFFER} } > BUFFER="gdb !!0 -x =(echo run !!1*)" } } If one of the args starts with - then won't that turn into an option to } echo? If $BUFFER starts with "-" it'll turn into an option to print -s, but the placement of "run" after "echo" means nothing beyond that will be treated as options. (For those who have been following the strange discussion on the austin-group list, zsh is not a GNU program and it does not in general interpret as options strings beginning with a "-" that appear after non-option operands.) Interpretation of various backslashed sequences in the arguments is another matter. From that standpoint, print -r would be better.