From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 19612 invoked from network); 12 Aug 2006 16:44:28 -0000 X-Spam-Checker-Version: SpamAssassin 3.1.4 (2006-07-25) 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.4 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 12 Aug 2006 16:44:28 -0000 Received-SPF: none (ns1.primenet.com.au: domain at sunsite.dk does not designate permitted sender hosts) Received: (qmail 35498 invoked from network); 12 Aug 2006 16:44:20 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 12 Aug 2006 16:44:20 -0000 Received: (qmail 19410 invoked by alias); 12 Aug 2006 16:44:13 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 10592 Received: (qmail 19401 invoked from network); 12 Aug 2006 16:44:13 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 12 Aug 2006 16:44:13 -0000 Received: (qmail 34511 invoked from network); 12 Aug 2006 16:44:13 -0000 Received: from dsl-63-249-88-2.cruzio.com (HELO dot.blorf.net) (63.249.88.2) by a.mx.sunsite.dk with SMTP; 12 Aug 2006 16:44:12 -0000 Received: by dot.blorf.net (Postfix, from userid 1000) id C98FB2E3A; Sat, 12 Aug 2006 09:44:10 -0700 (PDT) Date: Sat, 12 Aug 2006 09:44:10 -0700 From: Wayne Davison To: Peter Stephenson Cc: Zsh Users' List Subject: Re: What would you say is the most-used way of indenting case labels Message-ID: <20060812164410.GB5309@blorf.net> References: <20060811142225.GA15429@parhelion.globnix.org> <200608111937.k7BJbfE6003802@pwslaptop.csr.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200608111937.k7BJbfE6003802@pwslaptop.csr.com> User-Agent: Mutt/1.5.12-2006-07-14 On Fri, Aug 11, 2006 at 08:37:41PM +0100, Peter Stephenson wrote: > Time for some audience participation. Do you prefer the following > style? [...] I like the case labels to be less indented than the code that follows. I personally put them at the same level as the case, and only include a statement on the same line if all the labels are really short and the commands a one-liner, so in the general case I'd separate them: foo () { case $1 in (a) print alpha print second print third ;; (b) print beta ;; (*) print omega ;; esac } I also like a 4-character indent. That's my preference... ..wayne..