From 0b5d0eb92c5be2f0ddb2fa73990f31e5654e57fe Mon Sep 17 00:00:00 2001 From: Lukasz Kasprzak Date: Mon, 14 Sep 2026 15:16:55 +0200 Subject: krino: 0.0.5 — keyword cache, t and d in review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- cmd/krino/common.go | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'cmd/krino/common.go') diff --git a/cmd/krino/common.go b/cmd/krino/common.go index 4552441..11e73c5 100644 --- a/cmd/krino/common.go +++ b/cmd/krino/common.go @@ -5,6 +5,7 @@ package main import ( "fmt" "io" + "path/filepath" "strings" "time" @@ -30,6 +31,11 @@ func minAgeOverride(g *globals) (d time.Duration, set bool, err error) { return d, true, nil } +// cacheDir is where every directory's keyword cache lives (spec §6.1). +func cacheDir() string { + return filepath.Join(xdg.CacheHome(), "krino") +} + // applyMinAge sets every loaded directory's min-age to d, for this run only. func applyMinAge(e *engine.Engine, d time.Duration) { for _, dir := range e.Dirs { -- cgit v1.3