Andy Spiegl wrote [2003/08/04]: > I want to put all files that match the regex pattern > "^/var/tmp/exec\.[0-9]+$" > into a list that I can then use in a foreach loop. > > How can I do that most easily? Not a "foreach" loop, but "for" should work, too: for i in /var/tmp/exec.[0-9][0-9]* ; do echo $i ; done > Thanks a lot, > Andy. Ciao, Thomas -- Thomas Köhler Email: jean-luc@xxxxxxxxxxxxxxxxx | LCARS - Linux <>< WWW: http://jeanluc-picard.de | for Computers IRC: jeanluc | on All Real PGP public key available from Homepage! | Starships
Attachment:
pgpBUU1obgpRL.pgp
Description: PGP signature