[ale] Need help with RE in egrep
Jim Lynch
ale_nospam at fayettedigital.com
Sat Sep 18 14:19:42 EDT 2010
I've been using regular expressions for years, but sometimes I just
can't find the right answer. I'm trying to generate a list of files in
a directory, excluding the top level hidden directories and files.
I've tried the following and nothing seems to work. Can someone please
direct me to the right answer?
find . | egrep -v '^\.*' | more
find . | egrep -v '^\./\.*' | more
find . | egrep -v '^\.\/\.*' | more
find . | egrep -v '^\.\/\.*$' | more
The output of file . is like
./file
./.hidden
I didn't think I need to escape the slash but out of desperation I tried it.
Thanks,
Jim.
More information about the Ale
mailing list