batch file - Strange Behavior with Wildcards and DIR Command in Command Prompt -


i've noticed when using dir in windows command line 1 particular case wildcards don't function i'd expect. example:

dir *.doc 

runs similar

dir *.doc* 

i've noticed behavior when wildcard directory precedes period (which important , frequent case). whats stranger if run either:

dir *.d dir *.do 

it execute expected. it's once hit 3 character extensions strange behavior starts. mentioned runs similar command above because if contents after *. not extension not return file. e.g.:

dir *.tar 

will not return file.tar.gz will return file.targa

why , how can avoided?

the extension part after last dot. before last dot filename, including dots ordinary characters.

also remember dir matches short , long names.


Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

gradle error "Cannot convert the provided notation to a File or URI" -

python - NameError: name 'subprocess' is not defined -