ygqiang 当前离线
少尉
Have I Told You Lately.128kbs.mp3想批量改成Have I Told You Lately.mp3 删除文件名里的某个关键字。比如“128kbs” setlocal enabledelayedexpansion for /f "delims=" %%i in ('dir /b /a-d *.mp3') do ( set "file=%%i" ren "%%i" "!file:.128kbs=!" )复制代码
评分人数
尘丶 当前离线
四级士官
@echo off&setlocal enabledelayedexpansion for /f "tokens=1,2,3,4,5 delims=\." %%a in ('dir /s /b *.mp3^|findstr "Have I Told You Lately.128kbs.mp3"') do ( cd /d %%a\%%b ren "%%c.%%d".%%e "Have I Told You Lately".mp3 ) pause复制代码
TOP
尘丶 发表于 2015-7-28 18:06
回复 ygqiang 我可以理解为把:《重生之超级战舰》作者:彩虹之门(冲突_admin-pc-PC_2015-07-27 ... 尘丶 发表于 2015-7-28 18:31
回复 ygqiang @echo on&setlocal enabledelayedexpansion for /f "tokens=1,2,3,4,5 delims=\. ... 尘丶 发表于 2015-7-28 18:39
flyinnet9 当前离线
@echo off set /p str=请输入搜索关键字: for /f "delims=" %%a in ('dir /a-d /b *.txt^|find "%str%"') do ren "%%a" %str%.txt复制代码
flyinnet9 发表于 2015-7-30 16:36
@echo off for /f "tokens=1,2 delims=(" %%a in ('dir /a-d /b /s *.txt') do ren "%%a(%%b" "%%~na.txt"复制代码
flyinnet9 发表于 2015-7-30 17:09
@echo off for /f "tokens=1,2 delims=(" %%a in ('dir /a-d /b /s *.*') do ren "%%a(%%b" "%%~na%%~xb"复制代码
000(冲突_admin-pc-PC_2015-07-27 21-28-26).txt 000(冲突_admin-pc-PC_2015-07-27 21-28-26).ppt 改成 ... flyinnet9 发表于 2015-7-30 17:30