-
Notifications
You must be signed in to change notification settings - Fork 73
Expand file tree
/
Copy pathdev.sh
More file actions
27 lines (23 loc) · 713 Bytes
/
Copy pathdev.sh
File metadata and controls
27 lines (23 loc) · 713 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
export PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
#Check Root
[ $(id -u) != "0" ] && { echo "${CFAILURE}Error: You must be root to run this script${CEND}"; exit 1; }
echo "测试区域,请勿随意使用"
echo "1.更新SSR-Bsah"
while :; do echo
read -p "请选择: " devc
if [[ ! $devc =~ ^[1-1]$ ]]; then
echo "${CWARNING}输入错误! 请输入正确的数字!${CEND}"
else
break
fi
done
if [[ $devc == 1 ]];then
rm -rf /usr/local/bin/ssr
rm -rf /usr/local/SSR-Bash-Python
cd /usr/local
git clone https://github.com/FunctionClub/SSR-Bash-Python
mv /usr/local/SSR-Bash-Python/ssr /usr/local/bin/
chmod +x /usr/local/bin/ssr
echo 'SSR-Bash升级成功!'
fi