From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25910 invoked from network); 20 Jan 2009 12:22:28 -0000 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.3 required=5.0 tests=AWL,BAYES_00 autolearn=ham version=3.2.5 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 20 Jan 2009 12:22:28 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 32496 invoked from network); 20 Jan 2009 12:22:23 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 20 Jan 2009 12:22:23 -0000 Received: (qmail 19659 invoked by alias); 20 Jan 2009 12:22:19 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 26375 Received: (qmail 19648 invoked from network); 20 Jan 2009 12:22:19 -0000 Received: from bifrost.dotsrc.org (130.225.254.106) by sunsite.dk with SMTP; 20 Jan 2009 12:22:19 -0000 Received: from cluster-g.mailcontrol.com (cluster-g.mailcontrol.com [208.87.233.190]) by bifrost.dotsrc.org (Postfix) with ESMTPS id A23E680271F0 for ; Tue, 20 Jan 2009 13:22:15 +0100 (CET) Received: from rly11g.srv.mailcontrol.com (localhost.localdomain [127.0.0.1]) by rly11g.srv.mailcontrol.com (MailControl) with ESMTP id n0KCLk0a019175 for ; Tue, 20 Jan 2009 12:22:11 GMT Received: from submission.mailcontrol.com (submission.mailcontrol.com [86.111.216.190]) by rly11g.srv.mailcontrol.com (MailControl) id n0KCLCwk017170 for zsh-workers@sunsite.dk; Tue, 20 Jan 2009 12:21:12 GMT Received: from cameurexb01.EUROPE.ROOT.PRI ([193.128.72.68]) by rly11g-eth0.srv.mailcontrol.com (envelope-sender Peter.Stephenson@csr.com) (MIMEDefang) with ESMTP id n0KCIZcK009553; Tue, 20 Jan 2009 12:21:12 +0000 (GMT) Received: from news01.csr.com ([10.103.143.38]) by cameurexb01.EUROPE.ROOT.PRI with Microsoft SMTPSVC(6.0.3790.3959); Tue, 20 Jan 2009 12:21:07 +0000 Received: from news01.csr.com (localhost.localdomain [127.0.0.1]) by news01.csr.com (8.14.2/8.13.4) with ESMTP id n0KCL279006914; Tue, 20 Jan 2009 12:21:02 GMT Received: from csr.com (pws@localhost) by news01.csr.com (8.14.2/8.14.2/Submit) with ESMTP id n0KCL2nd006910; Tue, 20 Jan 2009 12:21:02 GMT Message-Id: <200901201221.n0KCL2nd006910@news01.csr.com> X-Authentication-Warning: news01.csr.com: pws owned process doing -bs To: tek@moonitor.org cc: zsh-workers@sunsite.dk Subject: Re: precmd reserved names In-reply-to: <200901201308.14694.tek@moonitor.org> References: <200901142124.14881.tek@moonitor.org> <200901181423.39539.tek@moonitor.org> <20090119094309.599c3ea4@news01> <200901201308.14694.tek@moonitor.org> Comments: In-reply-to tek message dated "Tue, 20 Jan 2009 13:08:10 +0100." Date: Tue, 20 Jan 2009 12:21:02 +0000 From: Peter Stephenson X-OriginalArrivalTime: 20 Jan 2009 12:21:07.0356 (UTC) FILETIME=[921C8DC0:01C97AF9] X-Scanned-By: MailControl A_08_51_00 (www.mailcontrol.com) on 10.71.1.121 X-Virus-Scanned: ClamAV 0.92.1/8878/Mon Jan 19 23:01:48 2009 on bifrost X-Virus-Status: Clean tek wrote: > Seems, not for me. It also doesn't need to be autoloaded, if it's called > prompt_foo_precmd_bar, it just isn't executed if it has exactly the > mentioned name. Ah, I see. Old hooks get deleted when the prompt is set up, just before prompt_*_setup is run. You need something like: add-zsh-hook precmd prompt_bart_precmd *inside* (or after) prompt_foo_setup. This did indeed change. How to add new prompts to the themes was never a documented interface, only how to use it; the only way to do it has bene to look at the existing themes. Feel free to supply documentation if you think it's lacking. -- Peter Stephenson Software Engineer CSR PLC, Churchill House, Cambridge Business Park, Cowley Road Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070