does find has feature to find several names
so that I don't have to write this: find . -type f -name "*.sh" -o -name "*.html" is there a find . -type f -name "*.sh|*.html" method? :D:D thank you
Re: does find has feature to find several names
On Sat, Jul 18, 2009 at 12:00 +0200, Soren Orel wrote: > so that I don't have to write this: > > find . -type f -name "*.sh" -o -name "*.html" > > is there a > > find . -type f -name "*.sh|*.html" man 1 find look for -regex hth Siggy -- Please don't cc: me when replying on the list. bsb-at-psycho-dot-informationsanarchistik-dot-de or:bsb-at-psycho-dot-i21k-dot-de signature.asc Description: Digital signature
Re: does find has feature to find several names
thank you, but i don't need regex, I'm just searching, that is there a shorter way in the find command to search for e.g.: two filenames find . -type f -name "*.sh" -o -name "*.html" so that I don't have to write "-o -name" at every time :D:P On Sat, Jul 18, 2009 at 12:08 PM, Siggy Brentrup wrote: > On Sat, Jul 18, 2009 at 12:00 +0200, Soren Orel wrote: > > so that I don't have to write this: > > > > find . -type f -name "*.sh" -o -name "*.html" > > > > is there a > > > > find . -type f -name "*.sh|*.html" > > man 1 find > > look for -regex > > hth > Siggy > -- > Please don't cc: me when replying on the list. >bsb-at-psycho-dot-informationsanarchistik-dot-de > or:bsb-at-psycho-dot-i21k-dot-de > > -BEGIN PGP SIGNATURE- > Version: GnuPG v1.4.9 (GNU/Linux) > > iEYEARECAAYFAkphnxQACgkQ94B/SGO8KQdMSACg05TkYwrTAOMJ6VSqauTlLN3U > 3I8An0jlpDdodMlgNpjjKrN5djauoixH > =pfUz > -END PGP SIGNATURE- > >
Re: does find has feature to find several names
On Sat, Jul 18, 2009 at 12:45 +0200, Soren Orel wrote: > thank you, but i don't need regex, I'm just searching, that is there a > shorter way in the find command to search for e.g.: two filenames > > find . -type f -name "*.sh" -o -name "*.html" > > so that I don't have to write "-o -name" at every time :D:P That's why I pointed you to find's -regex predicate, I'm using it regularly but I wont't figure it out for you. Thanks Siggy -- Please don't cc: me when replying on the list. bsb-at-psycho-dot-informationsanarchistik-dot-de or:bsb-at-psycho-dot-i21k-dot-de signature.asc Description: Digital signature
Re: does find has feature to find several names
On Sat, Jul 18, 2009 at 12:45:43PM +0200, Soren Orel wrote: > thank you, but i don't need regex, I'm just searching, that is there a > shorter way in the find command to search for e.g.: two filenames Yes you do, regex is short for regular expression. It is used for pattern matching, which is exactly what you are trying to do. Cheers, Tom -- Not every problem someone has with his girlfriend is necessarily due to the capitalist mode of production. -- Herbert Marcuse signature.asc Description: Digital signature
Re: does find has feature to find several names
In <60f50c4a0907180345s21ecd941w29b8be4319e53...@mail.gmail.com>, Soren Orel wrote: >thank you, but i don't need regex, I'm just searching, that is there a >shorter way in the find command to search for e.g.: two filenames > >find . -type f -name "*.sh" -o -name "*.html" > >so that I don't have to write "-o -name" at every time :D:P Using regex: find . -type f -regex '.*\.(sh|html)' -- Boyd Stephen Smith Jr. ,= ,-_-. =. b...@iguanasuicide.net ((_/)o o(\_)) ICQ: 514984 YM/AIM: DaTwinkDaddy `-'(. .)`-' http://iguanasuicide.net/\_/ signature.asc Description: This is a digitally signed message part.