From 618470091c4ddb42fbbba39d25eae9cb1dc25f96 Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Tue, 25 Oct 2022 14:52:39 +0800 Subject: [PATCH 1/2] =?UTF-8?q?:art:=20=E6=A1=8C=E9=9D=A2=E7=AB=AF?= =?UTF-8?q?=E5=86=85=E6=A0=B8=E8=BF=9B=E7=A8=8B=E4=BD=BF=E7=94=A8=E9=9A=8F?= =?UTF-8?q?=E6=9C=BA=E7=AB=AF=E5=8F=A3=20https://github.com/siyuan-note/si?= =?UTF-8?q?yuan/issues/4952?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/electron/main.js | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/app/electron/main.js b/app/electron/main.js index 9d99d192c..ccfbd40ec 100644 --- a/app/electron/main.js +++ b/app/electron/main.js @@ -560,11 +560,8 @@ const initKernel = (initData) => { `
数据库文件正在被其他程序锁定。如果你使用了第三方同步盘,请在思源运行期间关闭同步。
The database file is being locked by another program. If you use a third-party sync disk, please turn off sync while SiYuan is running.
`) break case 21: - showErrorWindow('⚠️ ' + kernelPort + ' 端口不可用 The port ' + kernelPort + ' is unavailable', - '
思源需要监听 ' + kernelPort + ' 端口,请确保该端口可用且不是其他程序的保留端口。可尝试使用管理员运行命令:' + - '
net stop winnat\nnetsh interface ipv4 add excludedportrange protocol=tcp startport=' + kernelPort + ' numberofports=1\nnet start winnat
' + - '
SiYuan needs to listen to port ' + kernelPort + ', please make sure this port is available, and not a reserved port by other software. Try running the command as an administrator: ' + - '
net stop winnat\nnetsh interface ipv4 add excludedportrange protocol=tcp startport=' + kernelPort + ' numberofports=1\nnet start winnat
') + showErrorWindow('⚠️ 监听端口 ' + kernelPort + ' 失败 Failed to listen to port ' + kernelPort, + '
监听 ' + kernelPort + ' 端口失败,请确保程序拥有网络权限并不受防火墙和杀毒软件阻止。
Failed to listen to port ' + kernelPort + ', please make sure the program has network permissions and is not blocked by firewalls and antivirus software.
') break case 22: showErrorWindow( From 81ecec5a0f267f202d0bf52adef862075dfe015a Mon Sep 17 00:00:00 2001 From: Liang Ding Date: Tue, 25 Oct 2022 14:56:46 +0800 Subject: [PATCH 2/2] =?UTF-8?q?:art:=20=E6=A1=8C=E9=9D=A2=E7=AB=AF?= =?UTF-8?q?=E5=86=85=E6=A0=B8=E8=BF=9B=E7=A8=8B=E4=BD=BF=E7=94=A8=E9=9A=8F?= =?UTF-8?q?=E6=9C=BA=E7=AB=AF=E5=8F=A3=20https://github.com/siyuan-note/si?= =?UTF-8?q?yuan/issues/4952?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/electron/main.js | 1 - 1 file changed, 1 deletion(-) diff --git a/app/electron/main.js b/app/electron/main.js index ccfbd40ec..a058820d4 100644 --- a/app/electron/main.js +++ b/app/electron/main.js @@ -530,7 +530,6 @@ const initKernel = (initData) => { cmds.push('--resident', 'false') if (isDevEnv) { cmds.push('--mode', 'dev') - cmds.push('--port', '6806') } if (initData) { const initDatas = initData.split('-')