functiontravFolder(){ #echo "travFolder start" flist=`ls$1` cd$1 for f in *.key; domv"$f""server.key"; done for f in *.crt; domv"$f""ssl.chain.crt"; done for f in$flist do #echo traverse do $f iftest -d $f then #echo "traverse dir:${f}" travFolder $f fi done cd ../ }
param=$1 if [ -z "$1" ] then param="./" echo"empty string: $param" else param=$1 fi travFolder $param