字符串处理

#packagenameを取得
packagenamekey=$(echo $packagefilename|sed -e "s/-.*//g")
packagenamemain=$(echo ${packagefilename%.*})
packagenameenv=$(echo ${packagenamemain##*.})
packagename=$packagenamekey.$packagenameenv

posted @ 2017-01-24 17:24  此媛非彼猿  阅读(77)  评论(0编辑  收藏  举报