Added session manager
This commit is contained in:
@@ -15,7 +15,7 @@ return {
|
|||||||
dashboard.section.header.val = logo
|
dashboard.section.header.val = logo
|
||||||
dashboard.section.buttons.val = {
|
dashboard.section.buttons.val = {
|
||||||
dashboard.button("f", " " .. "Find files", ":Telescope find_files <CR>"),
|
dashboard.button("f", " " .. "Find files", ":Telescope find_files <CR>"),
|
||||||
dashboard.button("p", " " .. "Select project", ":Telescope project <CR>"),
|
dashboard.button("p", " " .. "Select project", ":Telescope neovim-project history <CR>"),
|
||||||
dashboard.button("n", " " .. "Neorg", ":Neorg workspace main <CR>"),
|
dashboard.button("n", " " .. "Neorg", ":Neorg workspace main <CR>"),
|
||||||
dashboard.button("l", " " .. "Lazy sync", ":Lazy sync <CR>"),
|
dashboard.button("l", " " .. "Lazy sync", ":Lazy sync <CR>"),
|
||||||
}
|
}
|
||||||
|
|||||||
31
lua/taken/plugins/sessionmanager.lua
Normal file
31
lua/taken/plugins/sessionmanager.lua
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
return {
|
||||||
|
"coffebar/neovim-project",
|
||||||
|
priority = 100,
|
||||||
|
dependencies = {
|
||||||
|
{ "nvim-lua/plenary.nvim" },
|
||||||
|
{ "nvim-telescope/telescope.nvim", tag = "0.1.0" },
|
||||||
|
{ "Shatur/neovim-session-manager" },
|
||||||
|
},
|
||||||
|
init = function()
|
||||||
|
vim.opt.sessionoptions:append("globals")
|
||||||
|
end,
|
||||||
|
config = function()
|
||||||
|
local project = require("neovim-project")
|
||||||
|
local smconfig = require("session_manager.config")
|
||||||
|
local sessionmanager = require("session_manager")
|
||||||
|
|
||||||
|
project.setup({
|
||||||
|
projects = {
|
||||||
|
"~/git/*",
|
||||||
|
"~/Appdata/Local/nvim",
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
sessionmanager.setup({
|
||||||
|
autoload_mode = smconfig.AutoloadMode.Disabled,
|
||||||
|
})
|
||||||
|
|
||||||
|
vim.keymap.set("n", "<leader>ps", "<cmd>Telescope neovim-project discover<CR>")
|
||||||
|
vim.keymap.set("n", "<leader>ph", "<cmd>Telescope neovim-project history<CR>")
|
||||||
|
end,
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user