mirror of
https://github.com/e1732a364fed/v2ray_simple.git
synced 2025-12-24 13:27:56 +08:00
添加 -cvqxtvs 和 -eqxrs 命令,
分别意思是 convert QX to verysimple 和 extract QX remote servers 将圈叉的配置文件转换为verysimple格式,这样就可以更快地使用自己的vs客户端
This commit is contained in:
@@ -26,6 +26,9 @@ var (
|
||||
cmdPrintVer bool
|
||||
cmdGenerateUUid bool
|
||||
|
||||
cmdConvertQxToVs string
|
||||
cmdExtractQX_remoteServer string
|
||||
|
||||
download bool
|
||||
|
||||
defaultApiServerConf machine.ApiServerConf
|
||||
@@ -34,10 +37,13 @@ var (
|
||||
)
|
||||
|
||||
func init() {
|
||||
flag.BoolVar(&download, "d", false, " automatically download required mmdb file")
|
||||
|
||||
flag.BoolVar(&cmdPrintSupportedProtocols, "sp", false, "print supported protocols")
|
||||
flag.BoolVar(&cmdPrintVer, "v", false, "print the version string then exit")
|
||||
flag.BoolVar(&download, "d", false, " automatically download required mmdb file")
|
||||
flag.BoolVar(&cmdGenerateUUid, "gu", false, " automatically generate a uuid for you")
|
||||
flag.StringVar(&cmdConvertQxToVs, "cvqxtvs", "", "if given, convert qx server config string to vs toml config")
|
||||
flag.StringVar(&cmdExtractQX_remoteServer, "eqxrs", "", "if given, automatically extract remote servers from quantumultX config for you")
|
||||
|
||||
//apiServer stuff
|
||||
|
||||
@@ -67,6 +73,18 @@ func runExitCommands() (atLeastOneCalled bool) {
|
||||
|
||||
generateAndPrintUUID()
|
||||
}
|
||||
|
||||
if cmdConvertQxToVs != "" {
|
||||
atLeastOneCalled = true
|
||||
|
||||
convertQxToVs()
|
||||
}
|
||||
|
||||
if cmdExtractQX_remoteServer != "" {
|
||||
atLeastOneCalled = true
|
||||
|
||||
extractQxRemoteServers()
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user