Add v2ray stats api

This commit is contained in:
世界
2022-09-26 19:37:06 +08:00
parent d967847370
commit 0ea767a809
32 changed files with 1408 additions and 64 deletions

17
include/clashapi_stub.go Normal file
View File

@@ -0,0 +1,17 @@
//go:build !with_clash_api
package include
import (
"github.com/sagernet/sing-box/adapter"
"github.com/sagernet/sing-box/experimental"
"github.com/sagernet/sing-box/log"
"github.com/sagernet/sing-box/option"
E "github.com/sagernet/sing/common/exceptions"
)
func init() {
experimental.RegisterClashServerConstructor(func(router adapter.Router, logFactory log.ObservableFactory, options option.ClashAPIOptions) (adapter.ClashServer, error) {
return nil, E.New(`clash api is not included in this build, rebuild with -tags with_clash_api`)
})
}