Results 1 to 2 of 2
I'm battling find right now.
I want to find any file that matches a path governed by the following regular expression: "(monthly|nightly).[0-9]+/home/(user1|user2)/.mailbox/"
to match files like:
monthly.1/home/user1/.mailbox/mail.txt
nightly.15/home/user2/.mailbox/cur/mail.txt
I've tried:
...
- 05-05-2010 #1Just Joined!
- Join Date
- Feb 2010
- Posts
- 7
find with regex
I'm battling find right now.
I want to find any file that matches a path governed by the following regular expression: "(monthly|nightly).[0-9]+/home/(user1|user2)/.mailbox/"
to match files like:
monthly.1/home/user1/.mailbox/mail.txt
nightly.15/home/user2/.mailbox/cur/mail.txt
I've tried:
regex1="(monthly|nightly).[0-9]+/home/(user1|user2)/.mailbox/"
find ./ -regextype posix-egrep -regex $regex1
and it just spins and never gives me an answer, even though the file structure isn't that big.
what am I missing?
- 05-06-2010 #2Just Joined!
- Join Date
- Feb 2010
- Posts
- 7
anyone have any ideas?


Reply With Quote