@echo off
::echo "hellow"
set /p diz= 请输入文件地址:
for /F "tokens=1 delims=:" %%i in ("%diz%") do @set nthstring=%%i
%nthstring%:& cd %diz%
set diz=
dir
set /p file=输入文件名:
echo 输入的文件为%file%
for /F "tokens=1 delims=." %%i in ("%file%") do @set nthstring=%%i
::set fill=%a:~0,-1%
if not exist %nthstring% (md "%nthstring%")
copy %file% %nthstring%
cd %nthstring%
echo 截取后文件名%nthstring%
gcc -v -w -save-temps %file% -o %nthstring%.exe
set file=
choice /c yn
if %errorlevel%==1 %nthstring%.exe
echo 按任意键退出 & pause
exit
::echo "hellow"
set /p diz= 请输入文件地址:
for /F "tokens=1 delims=:" %%i in ("%diz%") do @set nthstring=%%i
%nthstring%:& cd %diz%
set diz=
dir
set /p file=输入文件名:
echo 输入的文件为%file%
for /F "tokens=1 delims=." %%i in ("%file%") do @set nthstring=%%i
::set fill=%a:~0,-1%
if not exist %nthstring% (md "%nthstring%")
copy %file% %nthstring%
cd %nthstring%
echo 截取后文件名%nthstring%
gcc -v -w -save-temps %file% -o %nthstring%.exe
set file=
choice /c yn
if %errorlevel%==1 %nthstring%.exe
echo 按任意键退出 & pause
exit