Make persistence work with normal sessions

This commit is contained in:
Marco Hinz 2014-06-11 12:14:21 +02:00
parent a4eef8c086
commit 19da8f9ee8
3 changed files with 40 additions and 37 deletions

View file

@ -18,6 +18,13 @@ augroup startify
\ endif |
\ autocmd! startify VimEnter
endif
if get(g:, 'startify_session_persistence')
autocmd startify VimLeave *
\ if exists('v:this_session') && filewritable(v:this_session) |
\ call startify#session_write(fnameescape(v:this_session)) |
\ endif
endif
augroup END
command! -nargs=? -bar -complete=customlist,startify#session_list SSave call startify#session_save(<f-args>)