-
-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Auto save enabled doesn't work #275
Comments
Can you still reproduce if you don't pass these two options at startup? auto_save_enabled = true,
auto_restore_enabled = false, |
I also noticed auto save stops working on some sessions. |
|
I usually change cwd through NeoTree, which probably do one of the others, as I can see different |
I noticed that My config:
|
My question is the same still, what happens if you don't pass these options at all? (they are already the default) |
I'm actually using https://github.com/Shatur/neovim-session-manager Actually from the docs I see that the 2 values have nil as default value. That's why I set the options up in the first place. |
It still won't autosave with the two options unset, here's my config: return {
{
'rmagatti/auto-session',
config = function()
vim.o.sessionoptions = 'blank,buffers,curdir,folds,help,tabpages,winsize,winpos,terminal,localoptions'
require('auto-session').setup {
log_level = 'info',
auto_session_enable_last_session = true,
auto_session_root_dir = vim.fn.stdpath 'data' .. '/sessions/',
auto_session_enabled = true,
-- auto_save_enabled = true,
-- auto_restore_enabled = false,
auto_session_suppress_dirs = nil,
auto_session_use_git_branch = nil,
-- the configs below are lua only
bypass_session_save_file_types = nil,
}
end,
lazy = false,
},
} |
@wonrax can you set |
I don't know how to pause to get the messages when doing neovim quit all, but session autoload works fine when I have manually created a save before. It just won't autosave on neovim quit. |
Yes, I see |
@wonrax you can run the autosaving logic without exiting using this command
Then you should be able to check the messages via |
I had the same issue. My projects folder is symlinked from |
@sakithb Ah, interesting. I think we can fix it so symlinks will match. I'll take a look. Is anyone else in this thread still having problems with auto-saving? The code has changed a lot since the original issue so I want to see if anyone is still having trouble. |
I just tried out this library and I have the same problem --- launching nvim creates the session, but autosave/autoreload will not work for that directory unless I run |
Never mind, I saw what the problem was --- the problem was that I was testing the plugin by doing This also explains why In short: PEBCAK. |
The code to support symlinks is now pushed so this should now work. If you test it, let me know! |
Closing. Can re-open if needed |
It works now! |
I want to save session buffer automatically before exit nvim with
:wqa
. I enableauto_save_enabled = true
. But It doesn't work. Here is my configuration.The text was updated successfully, but these errors were encountered: