diff options
| author | Jeff Carr <[email protected]> | 2025-09-02 15:18:27 -0500 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2025-09-02 15:18:27 -0500 |
| commit | 589d50d95019638ca394382cbc6b21c6b248888d (patch) | |
| tree | b2a333eda4d8264327c5e45f0eb46647e325f464 /doClean.go | |
| parent | 81343b3b66fdbca76790dd3ac340d6cb82d4540c (diff) | |
convert is working okay
Diffstat (limited to 'doClean.go')
| -rw-r--r-- | doClean.go | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -36,7 +36,7 @@ func scanTmp() { if !strings.HasPrefix(fname, "regex.") { return nil } - if count > 5 { + if count > 10 { return log.Errorf("count exceeded") } if strings.HasPrefix(fname, "regex.gemini-api-response") { @@ -87,6 +87,11 @@ func cleanGeminiFile(fullname string) error { return log.Errorf("parsePB() == nil") } uuid := parts[1] + if argv.Clean.Match != "" { + if !strings.HasPrefix(uuid, argv.Clean.Match) { + return log.Errorf("uuid %s does not match %s", uuid, argv.Clean.Match) + } + } if chat := me.chats.FindUuid(uuid); chat != nil { log.Info("found uuid in chat", uuid, pb.Model, chat.Uuid) statf, err := os.Stat(fullname) @@ -94,7 +99,6 @@ func cleanGeminiFile(fullname string) error { age := statf.ModTime() if chat.AddGeminiRequest(fname, age, pb) { me.chats.ConfigSave() - okExit("") } else { log.Info("file was perfect. os.Remove() here", fullname) os.Remove(fullname) |
