//列表内容 list.txt
aaa/111.jpg|bbb/111.jpg
aaa/222.jpg|bbb/222.jpg
...
//sh脚本 demo.sh
#!/bin/bash
while read line
do
if [ -f "${line%|*}" ];then
cp -r ${line%|*} ${line#*|}
fi
done < ./list.txt
如果提示 bash: $’\r’: command not found
#使用vi打开文件
vi demo.sh
#转换格式
:set ff=unix
#保存文件
:wq