diff --git a/doc/nvim-tree-lua.txt b/doc/nvim-tree-lua.txt index 37136524..5185bbcc 100644 --- a/doc/nvim-tree-lua.txt +++ b/doc/nvim-tree-lua.txt @@ -1332,8 +1332,8 @@ In the event of a problem please disable the experiment and raise an issue. Configuration for diagnostic logging. *nvim-tree.log.enable* - Enable logging to a file `nvim-tree.log` in |stdpath| `"cache"`, usually - `$XDG_CACHE_HOME/nvim` + Enable logging to a file `nvim-tree.log` in |stdpath| `"log"`, usually + `${XDG_STATE_HOME}/nvim` Type: `boolean`, Default: `false` *nvim-tree.log.truncate* diff --git a/lua/nvim-tree/log.lua b/lua/nvim-tree/log.lua index 7d488e97..10d5c4dc 100644 --- a/lua/nvim-tree/log.lua +++ b/lua/nvim-tree/log.lua @@ -71,7 +71,7 @@ end function M.setup(opts) M.config = opts.log if M.config and M.config.enable and M.config.types then - M.path = string.format("%s/nvim-tree.log", vim.fn.stdpath "cache", os.date "%H:%M:%S", vim.env.USER) + M.path = string.format("%s/nvim-tree.log", vim.fn.stdpath "log", os.date "%H:%M:%S", vim.env.USER) if M.config.truncate then os.remove(M.path) end