@echo off
rem @set aa=ccc
rem md %aa%
cd vsim
FOR /F "delims==" %%i IN ('dir *.v /b') do (@ echo %%i >>..\1.txt)
rem for /r %%i in (*.v) do (@ echo %%i >>1.txt)
cd ..
FOR /F "eol=; tokens=* delims=,- " %%i in (1.txt) do (
mkdir aa\%%i
rem @FOR /F "delims==" %%i IN ('dir /b') DO ( set temp=%i% & @echo %temp%
rem set temp %%i:.v=%
rem set temp=%%i%
rem mkdir aa\%temp%
)
del 1.txt
@pause