I would like to translate this Linux/Bash script to Windows shell:
if test -d myDirName; then echo "ok"; else mkdir myDirName; fi
It tests if a directory exists, and if it doesn't it creates it.
|
I would like to translate this Linux/Bash script to Windows shell:
It tests if a directory exists, and if it doesn't it creates it.
| ||||
|
feedback
|
| |||||||||
feedback
|
|
Here is what I just found out: You can test if a nul file exists; if the directory exists it will contain a nul file, if the nul file does not exist then the directory does not exist.
| ||||
feedback
|
|
Use a backslash, not forward slash:
-- foo is a directory | ||||
|
feedback
|
also is true if myDirName is a file, whis is not the searched functionality | |||
|
feedback
|