-
Notifications
You must be signed in to change notification settings - Fork 4
/
session.lua
34 lines (34 loc) · 1.37 KB
/
session.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
return {
{ "folke/persistence.nvim", enabled = false },
{
"olimorris/persisted.nvim",
-- event = "BufReadPre",
config = function()
require("persisted").setup()
require("telescope").load_extension("persisted")
end,
},
{
"goolord/alpha-nvim",
opts = function(_, opts)
-- local dashboard = opts
local dashboard = require("alpha.themes.dashboard")
-- dashboard.section.buttons.val = {
opts.section.buttons.val = {
dashboard.button("f", " " .. " Find file", ":Telescope find_files <CR>"),
dashboard.button("n", " " .. " New file", ":ene <BAR> startinsert <CR>"),
dashboard.button("r", " " .. " Recent files", ":Telescope oldfiles <CR>"),
dashboard.button("g", " " .. " Find text", ":Telescope live_grep <CR>"),
dashboard.button("c", " " .. " Config", ":e $MYVIMRC <CR>"),
dashboard.button("s", " " .. " Restore Session", [[:lua require("persisted").load() <cr>]]),
dashboard.button("S", "T " .. " Restore Session(T)", [[:Telescope persisted<cr>]]),
dashboard.button("l", " " .. " Lazy", ":Lazy<CR>"),
dashboard.button("q", " " .. " Quit", ":qa<CR>"),
}
for _, button in ipairs(dashboard.section.buttons.val) do
button.opts.hl = "AlphaButtons"
button.opts.hl_shortcut = "AlphaShortcut"
end
end
},
}