loops - Batch file, looping through files and check existence based on extenstions -


i new batch files, might seem bit noob-ish, here goes :) trying apply procedures on files in folder - loop through files in folder, having no extension, or having .csv extension (this part figured out:

for %%i in (*.csv *.) <command> %%i -s 

but want skip if have %%i.txt file in folder (i.e. - command files not have corresponding .txt file int folder). part can't quite figure out... appreciated

thanks in advance!

like :

for %%i in (*.csv *.) if not exist "%%~ni.txt" <command> %%i -s 

Comments

Popular posts from this blog

javascript - AngularJS custom datepicker directive -

javascript - jQuery date picker - Disable dates after the selection from the first date picker -