慢慢赚钱博客

4月 7 2019

shell find sed 批量修改文件名

比如替换pic_001 为 001

for file in `find . -type f`

do

newfile=`echo $file | sed 's/pic_//g'`

mv $file $newfile

done

Written by moneyslow.com

moneyslow.com真棒!