diff --git a/lua/avante/path.lua b/lua/avante/path.lua index 46f20c5..c3136eb 100644 --- a/lua/avante/path.lua +++ b/lua/avante/path.lua @@ -181,6 +181,9 @@ P.available = function() return templates ~= nil end P.clear = function() P.cache_path:rm({ recursive = true }) P.history_path:rm({ recursive = true }) + + if not P.cache_path:exists() then P.cache_path:mkdir({ parents = true }) end + if not P.history_path:exists() then P.history_path:mkdir({ parents = true }) end end return P