Skip to content

How do i set up SaveSession to save automatically to the currently open session? #137

Answered by rmagatti
bokonist asked this question in Q&A
Discussion options

You must be logged in to vote

Something I've been meaning to implement for a while now is cwd tracking. It's now possible because Neovim provides a DirChanged and DirChangedPre aucmds.
https://sourcegraph.com/github.com/neovim/neovim/-/blob/src/nvim/auevents.lua

What this would do is track that the cwd changed within the plugin and then do something with that information. That something would probably be to ignore a SaveSession happening when a cwd changes to start with.

Replies: 1 comment 7 replies

Comment options

You must be logged in to vote
7 replies
@bokonist
Comment options

@howabouthis
Comment options

@rmagatti
Comment options

@howabouthis
Comment options

@rmagatti
Comment options

Answer selected by rmagatti
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants