From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 1096 invoked from network); 30 Jun 2006 18:22:48 -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; 30 Jun 2006 18:22:48 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 60405 invoked from network); 30 Jun 2006 18:22:42 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 30 Jun 2006 18:22:42 -0000 Received: (qmail 28203 invoked by alias); 30 Jun 2006 18:22:34 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10459 Received: (qmail 28193 invoked from network); 30 Jun 2006 18:22:34 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 30 Jun 2006 18:22:34 -0000 Received: (qmail 59129 invoked from network); 30 Jun 2006 18:22:34 -0000 Received: from mout.perfora.net (217.160.230.40) by a.mx.sunsite.dk with SMTP; 30 Jun 2006 18:22:33 -0000 Received: from [63.238.186.10] (helo=[10.0.139.90]) by mrelay.perfora.net (node=mrelayus0) with ESMTP (Nemesis), id 0MKoyl-1FwNdP15dX-0002QV; Fri, 30 Jun 2006 14:22:32 -0400 Mime-Version: 1.0 (Apple Message framework v752.2) In-Reply-To: <20060630124048.GA18152@ulpmm.u-strasbg.fr> References: <20060630124048.GA18152@ulpmm.u-strasbg.fr> Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: <382CBF20-4B12-4BFF-91A7-105C4239E6FD@petmystone.com> Content-Transfer-Encoding: 7bit From: Timothy Stone Subject: Prompt truncating... Date: Fri, 30 Jun 2006 14:22:14 -0400 To: zsh-users X-Pgp-Agent: GPGMail 1.1.2 (Tiger) X-Mailer: Apple Mail (2.752.2) X-Provags-ID: perfora.net abuse@perfora.net login:cc8f2e2326446829c1b030dcda0c3df2 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 /From Bash to Z Shell/ has a great chapter on truncating the path in the prompt for ZSH. There is some illusion to truncation "by segment" vs. total length: "...The example therefore shows you how to limit the amount of a directory printed by the total number of characters rather than by the numbers of segments in the path." Page 157-156, Chapter 7 So how to by segment? Is it in the Bash section of this chapter? I skipped that part. :) How I do it in tcsh now: if ($?prompt) then set prompt = "%n@%m %B[%b%c03%B]%b %% " # doesn't want to work in ZSH set cdpath = (~ ~/Documents ~/Projects) set ellipsis endif Basically, total length is nice, but not as nice as by segment, IMHO. Thanks, Tim - -- Timothy Stone | www dot petmystone dot com Rising Sun, MD | tstone at petmystone dot com "This Satan's drink [coffee] is so delicious... we shall cheat Satan by baptizing it." Pope Clement VIII (1592-1605) -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (Darwin) iD8DBQFEpWvmlNb2aYI3YNkRAuh2AJwPVHakUoAAcCAhD6AvpGKu7QKCnQCePx0p PYvgRibKMvIa32K4D8KzrF0= =NhAZ -----END PGP SIGNATURE-----