From 9c3fff8510c2c7fdbaad06308ee9ed0eba036f5e Mon Sep 17 00:00:00 2001 From: 2dust <31833384+2dust@users.noreply.github.com> Date: Tue, 20 Sep 2022 20:19:31 +0800 Subject: [PATCH] fix sing-box support --- v2rayN/v2rayN/Global.cs | 2 +- v2rayN/v2rayN/Handler/LazyConfig.cs | 6 +++--- v2rayN/v2rayN/Mode/ECoreType.cs | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/v2rayN/v2rayN/Global.cs b/v2rayN/v2rayN/Global.cs index 52bf04f9..22da556f 100644 --- a/v2rayN/v2rayN/Global.cs +++ b/v2rayN/v2rayN/Global.cs @@ -20,7 +20,7 @@ namespace v2rayN public const string hysteriaCoreUrl = "https://github.com/HyNetwork/hysteria/releases"; public const string naiveproxyCoreUrl = "https://github.com/klzgrad/naiveproxy/releases"; public const string tuicCoreUrl = "https://github.com/EAimTY/tuic/releases"; - public const string sing-boxCoreUrl = "https://github.com/SagerNet/sing-box/releases"; + public const string singboxCoreUrl = "https://github.com/SagerNet/sing-box/releases"; public const string geoUrl = "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/{0}.dat"; diff --git a/v2rayN/v2rayN/Handler/LazyConfig.cs b/v2rayN/v2rayN/Handler/LazyConfig.cs index 2c42d0c8..eb5ae6b9 100644 --- a/v2rayN/v2rayN/Handler/LazyConfig.cs +++ b/v2rayN/v2rayN/Handler/LazyConfig.cs @@ -184,10 +184,10 @@ namespace v2rayN.Handler coreInfos.Add(new CoreInfo { - coreType = ECoreType.sing-box, + coreType = ECoreType.sing_box, coreExes = new List { "sing-box-client", "sing-box" }, - arguments = "-c config.json", - coreUrl = Global.sing-boxCoreUrl + arguments = "run", + coreUrl = Global.singboxCoreUrl }); } diff --git a/v2rayN/v2rayN/Mode/ECoreType.cs b/v2rayN/v2rayN/Mode/ECoreType.cs index b66abba9..b3723d60 100644 --- a/v2rayN/v2rayN/Mode/ECoreType.cs +++ b/v2rayN/v2rayN/Mode/ECoreType.cs @@ -12,7 +12,7 @@ namespace v2rayN.Mode hysteria = 21, naiveproxy = 22, tuic = 23, - sing-box = 24, + sing_box = 24, v2rayN = 99 } }