From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20856 invoked from network); 5 Sep 2007 19:33:00 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.3 (2007-08-08) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.3 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 5 Sep 2007 19:33:00 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 67945 invoked from network); 5 Sep 2007 19:32:53 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 5 Sep 2007 19:32:53 -0000 Received: (qmail 13833 invoked by alias); 5 Sep 2007 19:32:45 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 11822 Received: (qmail 13819 invoked from network); 5 Sep 2007 19:32:44 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 5 Sep 2007 19:32:44 -0000 Received: (qmail 66796 invoked from network); 5 Sep 2007 19:32:44 -0000 Received: from smtpout0186.sc1.he.tucows.com (HELO n082.sc1.he.tucows.com) (64.97.136.186) by a.mx.sunsite.dk with SMTP; 5 Sep 2007 19:32:37 -0000 Received: from sc.homeunix.net (82.26.167.172) by n082.sc1.he.tucows.com (7.2.069.1) id 4630CFCB009C29D9; Wed, 5 Sep 2007 19:32:33 +0000 Received: from chazelas by sc.homeunix.net with local (Exim 4.67) (envelope-from ) id 1IT0bf-0004wd-Gk; Wed, 05 Sep 2007 20:32:07 +0100 Date: Wed, 5 Sep 2007 20:32:07 +0100 From: Stephane Chazelas To: Matthew Wozniski Cc: zsh-users@sunsite.dk Subject: Re: preexec hook: possible enhancement? Message-ID: <20070905193207.GB6029@sc.homeunix.net> Mail-Followup-To: Matthew Wozniski , zsh-users@sunsite.dk References: <20070905163417.GB26710@mastermind> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20070905163417.GB26710@mastermind> User-Agent: Mutt/1.5.16 (2007-06-11) On Wed, Sep 05, 2007 at 12:34:17PM -0400, Matthew Wozniski wrote: > While we're on the topic of using the preexec hook to set the > titlebar, I'd like to bounce something off the list and see if 1) it's > possible and 2) people would consider it useful. So, would it be > possible and/or useful to have the preexec hook (or some other, new > hook) fire once for each pipeline in the current command, rather > than just once using the entire current line? > > For instance, if one were to type > % xterm ; echo google.com | xargs w3m ; gnome-terminal > could a hook be inserted to fire once with "xterm", once with "echo > google.com | xargs w3m", and once with "gnome-terminal" passed to it, > rather than just once with > "xterm ; echo google.com | xargs w3m ; gnome-terminal" passed to it? > > It's by no means a necessary feature, and I don't know if others would > even find it useful, but I think it would be pretty cool to watch the > titlebar change as we moved from one pipeline to the next. [...] Hi Matthew, You can probably do that already with the DEBUG trap or TRAPDEBUG() -- Stéphane