Add network test command

This commit is contained in:
Ben Adrian Sarmiento
2024-06-16 09:47:29 +02:00
parent f4d3f273f6
commit 42a08583ce
7 changed files with 60 additions and 47 deletions

View File

@@ -45,7 +45,15 @@ func main() {
},
}
rootCmd.AddCommand(versionCmd, clearDownloadsCmd, clearTorrentsCmd)
var networkTestCmd = &cobra.Command{
Use: "network-test",
Short: "Test your network with RD servers",
Run: func(cmd *cobra.Command, args []string) {
internal.NetworkTest()
},
}
rootCmd.AddCommand(versionCmd, clearDownloadsCmd, clearTorrentsCmd, networkTestCmd)
if err := rootCmd.Execute(); err != nil {
fmt.Println(err)