Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var InitCmd = &cobra.Command{ Use: "init", Short: "init and check config", Long: `auto create config file or check config, and auto add new key and delete old key`, RunE: Init, }
View Source
var RootCmd = &cobra.Command{
Use: "synctv-server",
Short: "synctv-server",
Long: `synctv-server https://github.com/synctv-org/synctv`,
}
View Source
var ServerCmd = &cobra.Command{ Use: "server", Short: "Start synctv-server", Long: `Start synctv-server`, PersistentPreRunE: Init, PreRunE: func(cmd *cobra.Command, args []string) error { return InitGinMode() }, Run: Server, }
View Source
var VersionCmd = &cobra.Command{ Use: "version", Short: "Print the version number of Sync TV Server", Long: `All software has versions. This is Sync TV Server's`, Run: func(cmd *cobra.Command, args []string) { fmt.Printf("Sync TV Server version %s\n", conf.Version) fmt.Printf("Sync TV Web version %s\n", conf.WebVersion) fmt.Printf("Git commit %s\n", conf.GitCommit) fmt.Printf("Go version %s\n", runtime.Version()) fmt.Printf("Built with %s\n", runtime.Compiler) fmt.Printf("OS/Arch %s/%s\n", runtime.GOOS, runtime.GOARCH) }, }
Functions ¶
func InitGinMode ¶
func InitGinMode() error
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.