Lua version of gitsession vim plugin Neovim plugin that automatically saves and loads sessions for a git based projects, based on branch name.
This plugin is still in development, so there is are unknown bugs and missing features.
Basically it uses (neo)vim :mksession and :source commands to save and load sessions, i am just tired to use them manually.
Load plugin with your plugin manager, for example with lazy:
{ "naaysayer/nvim-gitsessions" }
plugin options and default values:
require("nvim-gitsessions").setup({
manual = true, -- save/load sessions manually, instead of using VimLeave and VimEnter events
path-- by default uses stdpath("data"), so it will be saved in ~/.local/share/nvim/data/nvim-gitsessions
})
Plugin provides commands:
NvimGitSessionsSave - save current session
NvimGitSessionsLoad - load session for current branch
NvimGitSessionsExplore - open nvim-gitsessions directory in netrw