Feat: sessions added to startify page#268
Conversation
|
@zhengrc19 Thanks! very helpful, that's the 1 feature I was really missing moving from vim to nvim. == EDIT === - never mind, I found out that the original "startify" plugin for Vim works also for Neovim, so that solves all of my problems :) |
Hey @itamark-targa thanks for reaching out! Yes in fact I was using |
|
vim-startify basically implements its own session management plugin, which is something i intentionally didn't include in |
|
i think i like this solution, i'll have to test it / see how it impacts statup times and such |
TLDR: Looks if neovim-session-manager is installed and if there are saved sessions. If both suffice, a new list of sessions is added on top of MRU CWD and MRU in the startify theme. This is supposed to solve #51 and #72.
Checks for installation of neovim-session-manager in
lua/alpha/themes/startify.lua:162.Creates buttons (with optional icons) according to the session filenames
lua/alpha/themes/startify.lua:164-202.Changes the numerical shortcuts according to number of sessions found in lines
lua/alpha/themes/startify.lua:229,243.Adds sessions to
sectioninlua/alpha/themes/startify.lua:212, and adds thissection.sessionstoconfig.layoutinlua/alpha/themes/startify.lua:267.The icons are turned off by default, configured in
lua/alpha/themes/startify.lua:61.P.S. This is my first PR ever so if there are any bad practices please point them out to me. Thanks!