From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20356 invoked by alias); 26 Mar 2017 21:24:52 -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: 22617 Received: (qmail 24819 invoked from network); 26 Mar 2017 21:24:52 -0000 X-Qmail-Scanner-Diagnostics: from know-smtprelay-omc-6.server.virginmedia.net by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(80.0.253.70):SA:0(-2.8/5.0):. Processed in 1.009491 secs); 26 Mar 2017 21:24:52 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H2,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.1 X-Envelope-From: p.w.stephenson@ntlworld.com X-Qmail-Scanner-Mime-Attachments: | X-Qmail-Scanner-Zip-Files: | Received-SPF: pass (ns1.primenet.com.au: SPF record at _smtprelay.virginmedia.com designates 80.0.253.70 as permitted sender) X-Originating-IP: [86.21.219.59] X-Spam: 0 X-Authority: v=2.1 cv=H94muLsi c=1 sm=1 tr=0 a=utowdAHh8RITBM/6U1BPxA==:117 a=utowdAHh8RITBM/6U1BPxA==:17 a=L9H7d07YOLsA:10 a=9cW_t1CCXrUA:10 a=s5jvgZ67dGcA:10 a=kj9zAlcOel0A:10 a=MWUjAzoEKyAA:10 a=MTFzOr7x3o1VzKU0wH8A:9 a=CjuIK1q_8ugA:10 Date: Sun, 26 Mar 2017 22:24:46 +0100 From: Peter Stephenson To: Zsh Users Subject: Re: spaces in filenames should be a crime. Message-ID: <20170326222446.4f8ed508@ntlworld.com> In-Reply-To: <0c1b9d89-edd0-a027-e2f1-d01c2d68fa4e@eastlink.ca> References: <0c1b9d89-edd0-a027-e2f1-d01c2d68fa4e@eastlink.ca> X-Mailer: Claws Mail 3.11.1 (GTK+ 2.24.28; x86_64-redhat-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Sun, 26 Mar 2017 13:22:24 -0700 Ray Andrews wrote: > mostrecent () > { > ls -l ${(f)$( find . -type f -printf "%T@ %p\n" | sort -n | cut > -d' ' -f 2- | tail -n 1 )} > } As Vadim says: mostrecent () { ls -l ${(f)"$( find . -type f -printf "%T@ %p\n" | sort -n | cut -d' ' -f 2- | tail -n 1 )"} } That's how (f) was designed to work. But "find -print0 | xargs -0 ' might also be your friend, and you might not actually need find. In fact, I'm sure there are ways of tidying this up I haven't got time for just now. pws