Making (Mac)Vim reopen with files open when closed

人盡茶涼 提交于 2019-12-02 17:21:25

I suggest you read about sessions :help session,that should answer your question. There are even nice scripts to deal with sessions.

Install this plugin: https://github.com/xolox/vim-session

And add this following two lines to your .vimrc :

let g:session_autosave = 'yes'
let g:session_autoload = 'yes'

Now if you close your MacVim/GVim it saves and loads the session automatically.

I suggest that you use session.vim Extended session management for Vim for session management as this plugin just works. You can automatically save your current session everytime you close vim or create a new session, close/open vim and load that session.

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!