2025-04-14 11:38:42 +01:00
|
|
|
return {
|
|
|
|
|
'folke/snacks.nvim',
|
|
|
|
|
priority = 1000,
|
|
|
|
|
lazy = false,
|
|
|
|
|
---@type snacks.Config
|
|
|
|
|
opts = {
|
|
|
|
|
-- your configuration comes here
|
|
|
|
|
-- or leave it empty to use the default settings
|
|
|
|
|
-- refer to the configuration section below
|
|
|
|
|
bigfile = { enabled = true },
|
2025-07-01 22:39:59 +01:00
|
|
|
dashboard = {
|
|
|
|
|
enabled = true,
|
|
|
|
|
preset = {
|
|
|
|
|
keys = {
|
|
|
|
|
{ icon = ' ', key = 'f', desc = 'Find File', action = ":lua Snacks.dashboard.pick('files')" },
|
|
|
|
|
{ icon = ' ', key = 'n', desc = 'New File', action = ':ene | startinsert' },
|
|
|
|
|
{ icon = ' ', key = 'g', desc = 'Find Text', action = ":lua Snacks.dashboard.pick('live_grep')" },
|
|
|
|
|
{ icon = ' ', key = 'r', desc = 'Recent Files', action = ":lua Snacks.dashboard.pick('oldfiles')" },
|
|
|
|
|
{ icon = ' ', key = 'c', desc = 'Config', action = ":lua Snacks.dashboard.pick('files', {cwd = vim.fn.stdpath('config')})" },
|
|
|
|
|
-- { icon = " ", key = "s", desc = "Restore Session", section = "session" },
|
|
|
|
|
{ icon = ' ', key = 'L', desc = 'Lazy', action = ':Lazy', enabled = package.loaded.lazy ~= nil },
|
|
|
|
|
{ icon = ' ', key = 'q', desc = 'Quit', action = ':qa' },
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
sections = {
|
|
|
|
|
{ section = 'header' },
|
|
|
|
|
{ section = 'keys', gap = 1, padding = 1 },
|
|
|
|
|
{
|
|
|
|
|
pane = 2,
|
|
|
|
|
icon = ' ',
|
|
|
|
|
title = 'Projects',
|
|
|
|
|
section = 'projects',
|
|
|
|
|
indent = 2,
|
|
|
|
|
padding = 1,
|
2025-07-01 22:44:17 +01:00
|
|
|
session = false,
|
2025-07-01 22:39:59 +01:00
|
|
|
dirs = function()
|
|
|
|
|
return {
|
|
|
|
|
vim.fn.expand '~/Code/Sites/runcats',
|
2025-07-19 11:52:57 +01:00
|
|
|
vim.fn.expand '~/Code/Sites/moovaza',
|
2025-07-01 22:39:59 +01:00
|
|
|
vim.fn.expand '~/Code/Sites/tuxtoolkit',
|
|
|
|
|
vim.fn.expand '~/Code/Sites/chrisstarling',
|
|
|
|
|
vim.fn.stdpath 'config',
|
|
|
|
|
}
|
|
|
|
|
end,
|
|
|
|
|
},
|
|
|
|
|
{ pane = 2, icon = ' ', title = 'Recent Files', section = 'recent_files', indent = 2, padding = 1 },
|
|
|
|
|
{
|
|
|
|
|
pane = 2,
|
|
|
|
|
icon = ' ',
|
|
|
|
|
title = 'Git Status',
|
|
|
|
|
section = 'terminal',
|
|
|
|
|
enabled = function()
|
|
|
|
|
return Snacks.git.get_root() ~= nil
|
|
|
|
|
end,
|
|
|
|
|
cmd = 'git status --short --branch --renames',
|
|
|
|
|
height = 5,
|
|
|
|
|
padding = 1,
|
|
|
|
|
ttl = 5 * 60,
|
|
|
|
|
indent = 3,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
},
|
2025-04-14 11:38:42 +01:00
|
|
|
indent = { enabled = true },
|
|
|
|
|
input = { enabled = true },
|
|
|
|
|
notifier = { enabled = true },
|
|
|
|
|
quickfile = { enabled = true },
|
|
|
|
|
scope = { enabled = true },
|
|
|
|
|
-- scroll = { enabled = true },
|
|
|
|
|
statuscolumn = { enabled = true },
|
|
|
|
|
words = { enabled = true },
|
|
|
|
|
terminal = { enabled = true },
|
|
|
|
|
scratch = { enabled = true },
|
|
|
|
|
rename = { enabled = true },
|
|
|
|
|
},
|
|
|
|
|
}
|