zsh-users
 help / color / mirror / code / Atom feed
* kinda perl grep ?
@ 2006-03-07 15:35 Marc Chantreux
  2006-03-07 15:44 ` Peter Stephenson
  2006-03-07 15:45 ` Clint Adams
  0 siblings, 2 replies; 5+ messages in thread
From: Marc Chantreux @ 2006-03-07 15:35 UTC (permalink / raw)
  To: zsh-users

Hi all,


in perl , i write :

@files = grep { chomp; -f $_ } `dpkg -L libapache2-mod-perl2`

in zsh :

for f ( $(dpkg -L libapache2-mod-perl2 ) ) { [[ -f $f  ]] && files+=$f }

i dream about something like

files=( ${$(dpkg -L libapache2-mod-perl2):[[ -f $_ ]]} )

or something like

arraygrep '-f $_ ' $(dpkg -L libapache2-mod-perl2)

someone to make the dream come true ?

regards
mc


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-03-08 14:58 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-03-07 15:35 kinda perl grep ? Marc Chantreux
2006-03-07 15:44 ` Peter Stephenson
2006-03-07 15:45 ` Clint Adams
2006-03-07 17:25   ` Bart Schaefer
2006-03-08 14:58     ` Marc Chantreux

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).