Skip to content

Commit

Permalink
update version
Browse files Browse the repository at this point in the history
  • Loading branch information
Jrohy committed Sep 21, 2019
1 parent 3e43820 commit 8cecb9a
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 15 deletions.
3 changes: 2 additions & 1 deletion Changelog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
> v3.6.1
> v3.6.2
* Added: 80端口cdn关闭(去掉域名)
* Added: 随机生成kcp header时增加wireguard header
* Changed: service命令变为systemctl

> v3.6.0
* Fixed: #218
Expand Down
14 changes: 6 additions & 8 deletions multi-v2ray.sh
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ removeV2Ray() {
#卸载V2ray官方脚本
systemctl stop v2ray >/dev/null 2>&1
systemctl disable v2ray >/dev/null 2>&1
service v2ray stop >/dev/null 2>&1
systemctl stop v2ray >/dev/null 2>&1
update-rc.d -f v2ray remove >/dev/null 2>&1
rm -rf /etc/v2ray/ >/dev/null 2>&1
rm -rf /usr/bin/v2ray >/dev/null 2>&1
Expand All @@ -107,9 +107,9 @@ removeV2Ray() {
rm -f crontab.txt >/dev/null 2>&1

if [[ ${OS} == 'CentOS' || ${OS} == 'Fedora' ]];then
service crond restart >/dev/null 2>&1
systemctl restart crond >/dev/null 2>&1
else
service cron restart >/dev/null 2>&1
systemctl restart cron >/dev/null 2>&1
fi

#删除multi-v2ray环境变量
Expand Down Expand Up @@ -189,13 +189,13 @@ planUpdate(){
OLD_CRONTAB=$(crontab -l)
echo "SHELL=/bin/bash" >> crontab.txt
echo "${OLD_CRONTAB}" >> crontab.txt
echo "0 ${LOCAL_TIME} * * * bash <(curl -L -s https://install.direct/go.sh) | tee -a /root/v2rayUpdate.log && service v2ray restart" >> crontab.txt
echo "0 ${LOCAL_TIME} * * * bash <(curl -L -s https://install.direct/go.sh) | tee -a /root/v2rayUpdate.log && systemctl restart v2ray" >> crontab.txt
crontab crontab.txt
sleep 1
if [[ ${OS} == 'CentOS' || ${OS} == 'Fedora' ]];then
service crond restart
systemctl restart crond
else
service cron restart
systemctl restart cron
fi
rm -f crontab.txt
colorEcho ${GREEN} "success open schedule update task: beijing time ${BEIJING_UPDATE_TIME}\n"
Expand Down Expand Up @@ -310,8 +310,6 @@ main() {

profileInit

service v2ray restart

installFinish
}

Expand Down
2 changes: 1 addition & 1 deletion v2ray_util/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
__version__ = '3.6.1'
__version__ = '3.6.2'

from .util_core.trans import _
10 changes: 5 additions & 5 deletions v2ray_util/global_setting/update_timer.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ def planUpdate():
else:
local_time = 3
os.system('echo "SHELL=/bin/bash" >> crontab.txt && echo "$(crontab -l)" >> crontab.txt')
os.system('echo "0 {} * * * bash <(curl -L -s https://install.direct/go.sh) | tee -a /root/v2rayUpdate.log && service v2ray restart" >> crontab.txt'.format(local_time))
os.system('echo "0 {} * * * bash <(curl -L -s https://install.direct/go.sh) | tee -a /root/v2rayUpdate.log && systemctl restart v2ray" >> crontab.txt'.format(local_time))
os.system("crontab crontab.txt && rm -f crontab.txt")
if IS_CENTOS:
os.system("service crond restart >/dev/null 2>&1")
os.system("systemctl restart crond >/dev/null 2>&1")
else:
os.system("service cron restart >/dev/null 2>&1")
os.system("systemctl restart cron >/dev/null 2>&1")
print(ColorStr.green(_("success open schedule update task!")))

def manage():
Expand Down Expand Up @@ -57,6 +57,6 @@ def manage():
os.system("crontab -l|sed '/SHELL=/d;/v2ray/d' > crontab.txt && crontab crontab.txt && rm -f crontab.txt")
print(ColorStr.green(_("close shedule task success")))
if IS_CENTOS:
os.system("service crond restart >/dev/null 2>&1")
os.system("systemctl restart crond >/dev/null 2>&1")
else:
os.system("service cron restart >/dev/null 2>&1")
os.system("systemctl restart cron >/dev/null 2>&1")

0 comments on commit 8cecb9a

Please sign in to comment.