#!/bin/sh for i in 01 02 03 04 do pushd "$i" ls *.txt | while read f do echo "${f:5}" cp "$f" "r/${f:5}" done popd done原文链接:https://www.f2er.com/angularjs/149266.html
#!/bin/sh for i in 01 02 03 04 do pushd "$i" ls *.txt | while read f do echo "${f:5}" cp "$f" "r/${f:5}" done popd done原文链接:https://www.f2er.com/angularjs/149266.html