https://github.com/indigoparadox/vimsaver
A tool to preserve a set of screen tabs and vim buffers in vim sessions within those tabs
https://github.com/indigoparadox/vimsaver
gnu-screen ide terminal vim
Last synced: 3 months ago
JSON representation
A tool to preserve a set of screen tabs and vim buffers in vim sessions within those tabs
- Host: GitHub
- URL: https://github.com/indigoparadox/vimsaver
- Owner: indigoparadox
- License: gpl-3.0
- Created: 2024-03-08T01:40:03.000Z (about 1 year ago)
- Default Branch: master
- Last Pushed: 2025-02-19T23:05:54.000Z (3 months ago)
- Last Synced: 2025-02-20T00:23:13.181Z (3 months ago)
- Topics: gnu-screen, ide, terminal, vim
- Language: Python
- Homepage:
- Size: 57.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: COPYING
Awesome Lists containing this project
README
# VIMSaver
A tool to preserve a set of screen tabs and vim buffers in vim sessions within those tabs.
## Setup
The following function is needed in the local .vimrc. The name of the function may be different, but it must then be specified with the -b option when running vimsaver.py.
> function! BufferList()
>
> execute "silent redir @m"
>
> execute "silent buffers"
>
> execute "silent redir END"
>
> let a=@m
>
> return a
>
> endfunction## Usage
In order to be preserved, vim sessions must be opened with a --servername. You might add `alias vimsn="vim --servername"` to your .bash\_aliases file, so you can type "vimsn gridcity gridcity.c" to open a vim session called gridcity with the file gridcity.c to start. Any additional tabs you open with :tabnew should then be preserved.
Screen sessions to be preserved should also be opened with a session name. This will use the default session name, vimsaver: `screen -S vimsaver`.
In order to restore a session, open a screen with a session name and then simply run `./vimsaver.py load` (it will assume the default session name vimsaver, please see help for details).