feat(脚本): 修改替换逻辑

pull/534/merge
mack-a 2020-06-11 15:54:22 +08:00
parent 17e6318a9e
commit ad72e0ebfc
1 changed files with 3 additions and 1 deletions

View File

@ -348,8 +348,10 @@ initV2RayConfig(){
if [[ ! -z "$1" ]]
then
sed -i "s/alone/${1}/g" `grep alone -rl /etc/v2ray/config.json`
else
sed -i "s/654765fe-5fb1-271f-7c3f-18ed82827f72/${uuid}/g" `grep 654765fe-5fb1-271f-7c3f-18ed82827f72 -rl /etc/v2ray/config.json`
fi
sed -i "s/654765fe-5fb1-271f-7c3f-18ed82827f72/${uuid}/g" `grep 654765fe-5fb1-271f-7c3f-18ed82827f72 -rl /etc/v2ray/config.json`
}
qrEncode(){
user=`cat /etc/v2ray/config.json|jq .inbounds[0]`