I have a file that lists filenames, each on it's own line, and I want to test if each exists in a particular directory. For example, some sample lines of the file might be
mshta.dll
foobar.dll
somethingelse.dll
The directory I'm interested in is X:\Windows\System32\
, so I want to see if the following files exist:
X:\Windows\System32\mshta.dll
X:\Windows\System32\foobar.dll
X:\Windows\System32\somethingelse.dll
How can I do this using the Windows command prompt? Also (out of curiosity) how would I do this using bash or another Unix shell?