Реализовано кеширование проверенных плейлистов, при включенном кеше -r теперь не учитывает только некешированные из ini-файла

This commit is contained in:
2025-05-08 11:14:59 +08:00
parent 994df87846
commit c1a7f7e289
10 changed files with 106 additions and 47 deletions

View File

@@ -9,7 +9,6 @@ package cmd
import (
"axenov/iptv-checker/app"
"axenov/iptv-checker/app/checker"
"axenov/iptv-checker/app/logger"
"encoding/json"
"fmt"
"github.com/spf13/cobra"
@@ -22,7 +21,7 @@ var checkCmd = &cobra.Command{
Use: "check",
Short: "Check playlists",
Run: func(cmd *cobra.Command, args []string) {
logger.Init(app.Args.NeedQuiet)
app.Init()
files, _ := cmd.Flags().GetStringSlice("file")
urls, _ := cmd.Flags().GetStringSlice("url")

View File

@@ -27,7 +27,6 @@ Copyright (c) 2025, Антон Аксенов, MIT license.`,
// 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)