local M = {} ---@class Persistence.Config local defaults = { dir = vim.fn.stdpath("state") .. "/sessions/", -- directory where session files are saved -- minimum number of file buffers that need to be open to save -- Set to 0 to always save need = 1, } ---@type Persistence.Config M.options = {} function M.setup(opts) M.options = vim.tbl_deep_extend("force", {}, defaults, opts or {}) vim.fn.mkdir(M.options.dir, "p") end return M