github.com/xraypb/xray-core@v1.6.6/core/core.go (about) 1 // Package core provides an entry point to use Xray core functionalities. 2 // 3 // Xray makes it possible to accept incoming network connections with certain 4 // protocol, process the data, and send them through another connection with 5 // the same or a difference protocol on demand. 6 // 7 // It may be configured to work with multiple protocols at the same time, and 8 // uses the internal router to tunnel through different inbound and outbound 9 // connections. 10 package core 11 12 //go:generate go run github.com/xraypb/xray-core/common/errors/errorgen 13 14 import ( 15 "runtime" 16 17 "github.com/xraypb/xray-core/common/serial" 18 ) 19 20 var ( 21 version = "1.6.5" 22 build = "Custom" 23 codename = "Xray, Penetrates Everything." 24 intro = "A unified platform for anti-censorship." 25 ) 26 27 // Version returns Xray's version as a string, in the form of "x.y.z" where x, y and z are numbers. 28 // ".z" part may be omitted in regular releases. 29 func Version() string { 30 return version 31 } 32 33 // VersionStatement returns a list of strings representing the full version info. 34 func VersionStatement() []string { 35 return []string{ 36 serial.Concat("Xray ", Version(), " (", codename, ") ", build, " (", runtime.Version(), " ", runtime.GOOS, "/", runtime.GOARCH, ")"), 37 intro, 38 } 39 }