Initial commit
All checks were successful
release / release (push) Successful in 5m47s

This commit is contained in:
2025-05-01 00:46:24 +08:00
commit d15d4f47b6
22 changed files with 1556 additions and 0 deletions

39
cmd/root.go Normal file
View File

@@ -0,0 +1,39 @@
/*
* Copyright (c) 2025, Антон Аксенов
* This file is part of iptvc project
* MIT License: https://git.axenov.dev/IPTV/iptvc/src/branch/master/LICENSE
*/
package cmd
import (
"axenov/iptv-checker/app"
"os"
"github.com/spf13/cobra"
)
// rootCmd represents the base command when called without any subcommands
var rootCmd = &cobra.Command{
Use: "iptvc",
Short: "Simple utility to check iptv playlists. Part of iptv.axenov.dev project.",
Long: `Simple utility to check iptv playlists. Part of iptv.axenov.dev project.
Copyright (c) 2025, Антон Аксенов, MIT license.`,
// Uncomment the following line if your bare application
// has an action associated with it:
// Run: func(cmd *cobra.Command, args []string) { },
}
// Execute adds all child commands to the root command and sets flags appropriately.
// This is called by main.main(). It only needs to happen once to the rootCmd.
func Execute() {
app.Init()
err := rootCmd.Execute()
if err != nil {
os.Exit(1)
}
}
func init() {
rootCmd.PersistentFlags().BoolVarP(&app.Args.Verbose, "verbose", "v", false, "enable additional output")
}