I have to find certain directory patterns.
All my patterns are in a property file.
One of directory patterns is :ABCmmddyyyy. (i.e ABC followed by 8 digits")
How can i find all the directories of this pattern by specifying a pattern in the property file
Since i have ABCmmddyyyy. (i.e ABC followed by 8 digits") as one of the directory patterns.
Can i have the place the pattern mentioned by "rdcwayx" in the property file and read it in the "find" command.
Wempy can u please elaborate a bit.. i didn't exactly get
That regular expression matches a string that:
(a) begins with the characters A, B and C, and
(b) is then followed by exactly 8 digits (0-9)
An equivalent regex is:
^ABC\d{8}$
Note that these regexes simply check for "8 digits after ABC" and not "8 digits after ABC that constitute a valid date of form MMDDYYYY".
If you want to do that, then that's a different problem altogether.
Otherwise, if those 8 digit numbers need not be validated, then these regexes can work.