From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 11474 invoked from network); 27 Aug 2002 10:35:43 -0000 Received: from sunsite.dk (130.225.247.90) by ns1.primenet.com.au with SMTP; 27 Aug 2002 10:35:43 -0000 Received: (qmail 11385 invoked by alias); 27 Aug 2002 10:35:25 -0000 Mailing-List: contact zsh-users-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 5297 Received: (qmail 11357 invoked from network); 27 Aug 2002 10:35:24 -0000 Date: Tue, 27 Aug 2002 12:34:27 +0200 From: Roman Neuhauser To: zsh-users@sunsite.dk Subject: Re: how to? Message-ID: <20020827103427.GJ21595@freepuppy.bellavista.cz> Mail-Followup-To: zsh-users@sunsite.dk References: <20020823133510.2B8EC5B5@mercea.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20020823133510.2B8EC5B5@mercea.net> User-Agent: Mutt/1.5.1i > From: Scott Lipcon > To: zsh-users@sunsite.dk > Subject: how to? > Date: Fri, 23 Aug 2002 09:35:10 -0400 > > Here's something I figure is possible in zsh, but I don't know how - > I'd like to be able to do an ls in a directory of source code while > its being built, and basically say: show me all the .c files for which > there doesn't exist a .o file. Right now I'm using: > > ls -1 *.[co] | cut -f 1 -d"." | uniq -c | grep 1 > > but there has to be a zsh way to do that without 3 pipes. Any ideas? This made me look in the uguide, and looks like there's a variation of this is (requires EXTENDED_GLOB): % print *.c~f* it works in this form, but isn't usable for the original task. Neither my copy of zsh manual nor user guide mention that this shouldn't work, but it doesn't: roman@freepuppy ~/tmp/foo 1030:0 > ls bar.c bar.o baz.c baz.o foo.c roman@freepuppy ~/tmp/foo 1031:0 > ls *.c~f* bar.c baz.c roman@freepuppy ~/tmp/foo 1032:0 > ls *.c~*.o bar.c baz.c foo.c roman@freepuppy ~/tmp/foo 1033:0 > could anyone explain this to me? -- FreeBSD 4.6-STABLE 12:19PM up 6 days, 18:12, 19 users, load averages: 0.04, 0.07, 0.02