::-----------------------------------------@echo off
setlocal EnableDelayedExpansion
set _thisFilePath=%0
:loop
for /r %%i in (*.*) do (
REM 文件全路径
set _filePath=%%i
REM 不删除批处理本身
if not "!_filePath!"==%_thisFilePath% (
REM 截取文件后缀
set suffix=!_filePath:~-4!
REM 不删除".vue"后缀的文件
if not "!suffix!"==".vue" (
del /q "%%i"
)
)
)
pause::----------------------------------------------------------