folke / persistence.nvim

💾 Simple session management for Neovim
Apache License 2.0
591 stars 26 forks source link

Suggestion: Use `~/.cache/nvim/sessions` for caching session data #20

Closed UtkarshVerma closed 1 year ago

UtkarshVerma commented 1 year ago

$XDG_CACHE_HOME/nvim/sessions (defualts ~/.cache/nvim/sessions would be a better directory for caching the session data according to the XDG directory specification.

https://wiki.archlinux.org/title/XDG_Base_Directory'

folke commented 1 year ago

We default to XDG_STATE_HOME, which is specifically meant for this purpose. https://github.com/folke/persistence.nvim/blob/8484fdaa284207f77ec69b9627316bf334ad653f/lua/persistence/config.lua#L5

UtkarshVerma commented 1 year ago

Oh, that's great then. I was misled by the README which mentions ~/.config/nvim/sessions being used.

folke commented 1 year ago

Ah good point. Will update the readme