#输入要修改的jar文件
echo "Please Input jar Name:(jar/servcie.jar)"
read jarName
#输入要修改jar内部文件名称
echo "Please Input file Name:(config.properties)"
read fileName
jar tvf $jarName |grep $fileName
#查询到的文件,选择要修改的文件
echo "Query out as follows,Please select the copy you want:"
read oldFilePath
jar xvf $jarName $oldFilePath
sleep 1
#复制你需要修改的文件
echo "Please Input replace file path:(like:config/config.properties)"
read newFilePath
cp $newFilePath $oldFilePath
echo "Replace success!"
jar uvf $jarName $oldFilePath
sleep 1
java -jar $jarName &