- @echo off
- setlocal enabledelayedexpansion
- set "FileOriginal=原始文本.txt"
- for /f "delims=" %%i in ('type "文件名列表.txt"') do (
- set /p FirtLine=<"%FileOriginal%"
- >"%%i" echo,!FirtLine!
- more +1 "%FileOriginal%" > "%FileOriginal%.tmp"
- move /y "%FileOriginal%.tmp" "%FileOriginal%" > nul
- )
复制代码
|