Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
修复路径解析问题,后台更新问题,优化tcp、kcp的tls配置,优化ss中文解码问题
Browse files Browse the repository at this point in the history
  • Loading branch information
jiangxufeng committed Nov 16, 2019
1 parent f3092ef commit 9400701
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 23 deletions.
25 changes: 12 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,28 +30,27 @@ v2ray linux 客户端,使用pyqt5编写GUI界面,核心基于v2ray-core(v2ra

# 使用

## 使用前请注意
使用脚本安装时下载的程序实在`ubuntu 18.04` + `Python3.6`的环境下打包的,因此在Python版本不一致的环境中可能会出现版本不兼容的问题

解决方法:

在自己的电脑上重新打包程序,具体方法如下(参考)
1. 运行`git clone https://github.com/jiangxufeng/v2rayL.git`
2. 进入项目文件夹,然后运行`pip install -r requirements.txt`
3. 运行`cd v2rayL-GUI && pyinstaller -F v2rayLui.py -p config.py -p sub2conf_api.py -p v2rayL_api.py -p v2rayL_threads.py -p utils.py -i images/logo.ico -n v2rayLui`
4. 打包后运行`mv dist/v2rayLui /usr/bin/v2rayL/v2rayLui`

## 安装
方法一:
```
bash <(curl -s -L http://dl.thinker.ink/install.sh)
```

方法二:
```
在release中下载最新的install.sh,然后运行 ./install.sh
```

## 更新
方法一:
``` bash
bash <(curl -s -L http://dl.thinker.ink/update.sh)
```

方法二:
``` bash
在release中下载最新的update.sh,然后运行 ./update.sh
```

## 卸载
``` bash
bash <(curl -s -L http://dl.thinker.ink/uninstall.sh)
Expand All @@ -61,7 +60,7 @@ bash <(curl -s -L http://dl.thinker.ink/uninstall.sh)

![首页](http://cloud.thinker.ink/download/a043a08860f239f8d0cbeb2dc2a5b6d5.png)

![setting1](http://cloud.thinker.ink/images/364231980b07e8881164f61cd220d0bb.png)
![setting1](http://cloud.thinker.ink/images/617ce660cc4a2a22bd275d73d0d7c616.png)

![setting2](http://cloud.thinker.ink/images/8835526765d479143879c08fe1ecb8a4.png)

Expand Down
8 changes: 6 additions & 2 deletions v2rayL-GUI/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,12 @@
conf_template = {
"dns": {
"servers": [
"1.1.1.1"
]
"1.1.1.1",
"8.8.8.8",
"8.8.4.4",
"localhost"
],

},
"inbounds": [{
"port": 1080,
Expand Down
6 changes: 3 additions & 3 deletions v2rayL-GUI/new_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -627,7 +627,7 @@ def retranslateUi(self, SystemSettings):
self.label_3.setText(_translate("SystemSettings", "Socks:"))
self.label_4.setText(_translate("SystemSettings", "版本更新"))
self.label_5.setText(_translate("SystemSettings", "当前版本:"))
self.version_label.setText(_translate("SystemSettings", "v2.1.1"))
self.version_label.setText(_translate("SystemSettings", "v2.1.2"))
self.checkupdateButton.setText(_translate("SystemSettings", "检查更新"))
self.label_7.setText(_translate("SystemSettings", "自动检查更新"))
self.label_6.setText(_translate("SystemSettings", "**端口可选范围:1080-10080,每次修改都将更新。**"))
Expand Down Expand Up @@ -659,7 +659,7 @@ def retranslateUi(self, HelpUi):
"</style></head><body style=\"; font-size:11pt; font-weight:400; font-style:normal;\">\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-size:16pt; font-weight:600;\">当前版本</span></p>\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-size:16pt;\">——————————————————————</span></p>\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-size:12pt;\">v2.1.1</span></p>\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-size:12pt;\">v2.1.2</span></p>\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><br /></p>\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-size:16pt; font-weight:600;\">说明</span></p>\n"
"<p align=\"center\" style=\" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-size:16pt;\">——————————————————————</span></p></body></html>"))
Expand Down Expand Up @@ -720,7 +720,7 @@ def setupUi(self, Form):
self.pushButton_1.setObjectName("pushButton_1")
self.time = QLabel(Form)
self.time.setGeometry(QRect(510, 400, 160, 31))
self.time.setStyleSheet('font: 75 11pt;font-weight:bold;')
self.time.setStyleSheet('font: 55 11pt;font-weight:500;')
self.time.setObjectName("time")

self.tableWidget.setShowGrid(False)
Expand Down
10 changes: 9 additions & 1 deletion v2rayL-GUI/sub2conf_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,13 +136,21 @@ def setconf(self, region, http, socks):
"uplinkCapacity": 12,
"writeBufferSize": 1
},
"security": "tls" if use_conf["tls"] else ""
"security": "tls" if use_conf["tls"] else "",
"tlssettings": {
"allowInsecure": True,
"serverName": use_conf["host"] if use_conf["tls"] else ""
}
}
# tcp
elif use_conf["net"] == "tcp":
conf['outbounds'][0]["streamSettings"] = {
"network": use_conf["net"],
"security": "tls" if use_conf["tls"] else "",
"tlssettings": {
"allowInsecure": True,
"serverName": use_conf["host"] if use_conf["tls"] else ""
},
"tcpsettings": {
"connectionReuse": True,
"header": {
Expand Down
2 changes: 0 additions & 2 deletions v2rayL-GUI/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -75,5 +75,3 @@ def qt_message_handler(mode, context, message):
if en == "True":
with open("/etc/v2rayL/v2rayL_op.log", "a+") as f:
f.write(' %s - %s: %s\n' % (datetime.datetime.now(), mode, info))

# https://sub.qianglie.xyz/subscribe.php?sid=5582&token=g6e8VdU6C40H
2 changes: 1 addition & 1 deletion v2rayL-GUI/v2rayL_threads.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def run(self):
with open("/etc/v2rayL/update.sh", 'w') as f:
f.write(req.text)

subprocess.call(["chmod +x /etc/v2rayL/update.sh && /etc/v2rayL/upda.sh"], shell=True)
subprocess.call(["chmod +x /etc/v2rayL/update.sh && /etc/v2rayL/update.sh"], shell=True)

self.sinOut.emit(("vrud", "@@OK@@", "更新完成, 重启程序生效.", None))

Expand Down
2 changes: 1 addition & 1 deletion v2rayL-GUI/v2rayLui.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def __init__(self, parent=None):
super(MyMainWindow, self).__init__(parent)

self.init_ui()
self.version = "2.1.1"
self.version = "2.1.2"

# 获取api操作
self.v2rayL = V2rayL()
Expand Down

0 comments on commit 9400701

Please sign in to comment.