summaryrefslogtreecommitdiff
path: root/cache.go
diff options
context:
space:
mode:
Diffstat (limited to 'cache.go')
-rw-r--r--cache.go5
1 files changed, 5 insertions, 0 deletions
diff --git a/cache.go b/cache.go
index d0b11e5..a81ea66 100644
--- a/cache.go
+++ b/cache.go
@@ -35,3 +35,8 @@ func WriteCache(relPath string, data []byte) error {
path := CachePath(relPath)
return os.WriteFile(path, data, 0o644)
}
+
+func ClearCache() error {
+ path := CachePath("")
+ return os.RemoveAll(path)
+}