Kiltme wrote:mike.+slide.+show
is the regex equivalent of the dos
mike*slide*show
file name search.
Actually, no. In DOS, (or at least in the current iterations of what used to be the DOS command shell) the character '*' means "zero to any number of any character", and '?' means "one of any character".
Open a command window and try it with dir. I think you'll find that
dir f*oo.txt will indeed match foo.txt.
That may be something new-ish and not in the old DOS command shell. It seems to me that the actual DOS shell was incapable of using *o*.txt to find foo.txt, where '*' had meant 'any number of any characters', but would then "swallow" them all. I
think that this is the way that many flavors of CP/M worked as well, but they varied a
lot. Intel came out with a version that used bits of something like PL/1 as a shell language.
The dot needs to be escaped with \ for it to be a dot and not a wildcard
Again no - not inside brackets. The only characters that need escaping inside brackets is ']' (for obvious reasons) and '\' itself. And I
think in some flavors of regex you don't need to escape '\' unless it's directly to the left of one of the characters that, outside of brackets, would have needed escaping.
Note that none of these will match mikeslideshow (neither the regex or the dos wildcard filters).
Actually any of the expressions using ? or * will match that.
? =
zero or one character
* = any number of characters, including
zero