-
- @echo off
- setlocal enabledelayedexpansion
- set "folder=D:\新建文件夹 (2)"
- for /f "delims=" %%i in ('dir /b "%folder%\mp3\*.mp3"') do (
- set t=
- for /f "delims=" %%j in ('findstr /i "%%i" "%folder%\1.txt" 2^>nul') do (
- set t=flag
- )
- if defined t (
- copy "%folder%\mp3\%%i" "%folder%\mp3 01\" /y
- ) else (
- copy "%folder%\mp3\%%i" "%folder%\mp3 02\" /y
- >>"%folder%\2.txt" echo %%i
- )
- )
- pause
复制代码
|