From 09a8b20b5f262fa79febcbf100c5494a121e65ef Mon Sep 17 00:00:00 2001 From: "Scott E. Graves" Date: Mon, 20 Oct 2025 15:07:31 -0500 Subject: [PATCH] updated README.md --- README.md | 61 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/README.md b/README.md index f39b438..c08a40d 100644 --- a/README.md +++ b/README.md @@ -104,3 +104,64 @@ end return M ``` + +### Default configuration + +```lua +local haven_config = { + enabled = true, + exclusions = { + function(path, _) + if gos.is_windows then + return path:lower():starts_with( + (vim.fn.eval("$VIMRUNTIME") .. gpath.directory_sep):lower() + ) + end + return path:starts_with(vim.fn.eval("$VIMRUNTIME") .. gpath.directory_sep) + end, + function(path, _) + if gos.is_windows then + return path:lower():starts_with( + (vim.fn.stdpath("data") .. gpath.directory_sep):lower() + ) + end + return path:starts_with(vim.fn.stdpath("data") .. gpath.directory_sep) + end, + function(path, _) + if gos.is_windows then + return path:lower():starts_with( + (gpath.create_path(vim.fn.eval("$XDG_CONFIG_HOME"), "coc") .. + gpath.directory_sep):lower() + ) + end + return path:starts_with( + gpath.create_path(vim.fn.eval("$XDG_CONFIG_HOME"), "coc") .. + gpath.directory_sep + ) + end, + function(path, _) + if gos.is_windows then + return path:lower():ends_with( + (gpath.directory_sep .. + ".git" .. gpath.directory_sep .. "COMMIT_EDITMSG"):lower() + ) + end + return path:ends_with( + gpath.directory_sep .. ".git" .. gpath.directory_sep .. "COMMIT_EDITMSG" + ) + end, + function(path, config) + if gos.is_windows then + return path:lower():starts_with( + (config.haven_path .. gpath.directory_sep):lower() + ) + end + return path:starts_with(config.haven_path .. gpath.directory_sep) + end + }, + haven_path = gpath.create_path(vim.fn.stdpath("data"), "nvim-haven"), + inclusions = {}, + max_history_count = 200, + save_timeout = 10000 +} +```