From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13107 invoked by alias); 2 Sep 2011 18:30:34 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 16304 Received: (qmail 10372 invoked from network); 2 Sep 2011 18:30:31 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_PASS autolearn=ham version=3.3.1 Received-SPF: pass (ns1.primenet.com.au: SPF record at m.gmane.org designates 80.91.229.12 as permitted sender) X-Injected-Via-Gmane: http://gmane.org/ To: zsh-users@zsh.org From: zzapper Subject: Re: listing sub-drectories with most files in Date: Fri, 2 Sep 2011 18:30:13 +0000 (UTC) Organization: SuccessTheory Message-ID: References: <110902100313.ZM8455@torch.brasslantern.com> X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: dsl78-143-228-30.in-addr.fast.co.uk User-Agent: Xnews/2006.08.24 X-Antivirus: avast! (VPS 110902-0, 02/09/2011), Outbound message X-Antivirus-Status: Clean Bart Schaefer wrote in news:110902100313.ZM8455@torch.brasslantern.com: > > This will give you the directories and the count of files in each, > in ascending order by number of files: > > print **/*(/ne{'reply=($REPLY/*(N.)); reply=($#reply\:$REPLY)'}) Bart: This will be super useful thanks. Minor quibble: on my system (Cygwin) it all jumbled onto one line I had to pipe it into Vim. Also in reverse order but that's not a problem. -- zzapper http://zzapper.co.uk/ Technical Tips