dashboard configured
This commit is contained in:
parent
6f06ad0baa
commit
e34b835fbf
|
@ -0,0 +1,50 @@
|
|||
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 },
|
||||
dashboard = {
|
||||
preset = {
|
||||
-- pick = function(cmd, opts)
|
||||
-- return LazyVim.pick(cmd, opts)()
|
||||
-- end,
|
||||
header = [[
|
||||
██╗ █████╗ ███████╗██╗ ██╗██╗ ██╗██╗███╗ ███╗ Z
|
||||
██║ ██╔══██╗╚══███╔╝╚██╗ ██╔╝██║ ██║██║████╗ ████║ Z
|
||||
██║ ███████║ ███╔╝ ╚████╔╝ ██║ ██║██║██╔████╔██║ z
|
||||
██║ ██╔══██║ ███╔╝ ╚██╔╝ ╚██╗ ██╔╝██║██║╚██╔╝██║ z
|
||||
███████╗██║ ██║███████╗ ██║ ╚████╔╝ ██║██║ ╚═╝ ██║
|
||||
╚══════╝╚═╝ ╚═╝╚══════╝ ╚═╝ ╚═══╝ ╚═╝╚═╝ ╚═╝
|
||||
]],
|
||||
-- stylua: ignore
|
||||
---@type snacks.dashboard.Item[]
|
||||
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 = "x", desc = "Lazy Extras", action = ":LazyExtras" },
|
||||
{ icon = " ", key = "l", desc = "Lazy", action = ":Lazy" },
|
||||
{ icon = " ", key = "q", desc = "Quit", action = ":qa" },
|
||||
},
|
||||
},
|
||||
},
|
||||
-- explorer = { enabled = true },
|
||||
-- indent = { enabled = true },
|
||||
-- input = { enabled = true },
|
||||
picker = { enabled = false },
|
||||
-- notifier = { enabled = true },
|
||||
-- quickfile = { enabled = true },
|
||||
-- scope = { enabled = true },
|
||||
-- scroll = { enabled = true },
|
||||
-- statuscolumn = { enabled = true },
|
||||
-- words = { enabled = true },
|
||||
},
|
||||
}
|
7
init.lua
7
init.lua
|
@ -32,3 +32,10 @@ require 'user.colorscheme'
|
|||
-- require 'user.autopairs'
|
||||
-- require 'user.nvim-tree'
|
||||
-- require 'user.bufferline'
|
||||
vim.api.nvim_create_autocmd('TextYankPost', {
|
||||
desc = 'Highlight when yanking (copying) text',
|
||||
group = vim.api.nvim_create_augroup('kickstart-highlight-yank', { clear = true }),
|
||||
callback = function()
|
||||
vim.highlight.on_yank()
|
||||
end,
|
||||
})
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
return {
|
||||
{ "wbthomason/packer.nvim" }, -- Have packer manage itself
|
||||
{ "nvim-lua/popup.nvim" }, -- An implementation of the Popup API from vim in Neovim
|
||||
{ "nvim-lua/plenary.nvim" }, -- Useful lua functions used ny lots of plugins
|
||||
{ "windwp/nvim-autopairs" }, -- Autopairs
|
||||
|
@ -10,26 +9,26 @@ return {
|
|||
-- "lunarvim/colorschemes" -- A bunch of colorschemes you can try out
|
||||
{ "lunarvim/darkplus.nvim" },
|
||||
{ "akinsho/bufferline.nvim" },
|
||||
{ "moll/vim-bbye" },
|
||||
-- cmp plugins
|
||||
{ "hrsh7th/nvim-cmp" }, -- The completion plugin
|
||||
{ "hrsh7th/cmp-buffer" }, -- buffer completions
|
||||
{ "hrsh7th/cmp-path" }, -- path completions
|
||||
{ "hrsh7th/cmp-cmdline" }, -- cmdline completions
|
||||
{ "saadparwaiz1/cmp_luasnip" }, -- snippet completions
|
||||
{ "hrsh7th/cmp-nvim-lsp" },
|
||||
{ "moll/vim-bbye" },
|
||||
-- cmp plugins
|
||||
{ "hrsh7th/nvim-cmp" }, -- The completion plugin
|
||||
{ "hrsh7th/cmp-buffer" }, -- buffer completions
|
||||
{ "hrsh7th/cmp-path" }, -- path completions
|
||||
{ "hrsh7th/cmp-cmdline" }, -- cmdline completions
|
||||
{ "saadparwaiz1/cmp_luasnip" }, -- snippet completions
|
||||
{ "hrsh7th/cmp-nvim-lsp" },
|
||||
|
||||
-- snippets
|
||||
{ "L3MON4D3/LuaSnip" }, --snippet engine
|
||||
{ "rafamadriz/friendly-snippets" }, -- a bunch of snippets to use
|
||||
-- snippets
|
||||
{ "L3MON4D3/LuaSnip" }, --snippet engine
|
||||
{ "rafamadriz/friendly-snippets" }, -- a bunch of snippets to use
|
||||
|
||||
-- LSP
|
||||
{ "neovim/nvim-lspconfig" }, -- enable LSP
|
||||
{ "williamboman/mason.nvim" }, -- simple to use language server installer
|
||||
{ "williamboman/mason-lspconfig.nvim" }, -- simple to use language server installer
|
||||
-- LSP
|
||||
{ "neovim/nvim-lspconfig" }, -- enable LSP
|
||||
{ "williamboman/mason.nvim" }, -- simple to use language server installer
|
||||
{ "williamboman/mason-lspconfig.nvim" }, -- simple to use language server installer
|
||||
|
||||
-- Telescope
|
||||
{ "nvim-telescope/telescope-media-files.nvim" },
|
||||
-- Telescope
|
||||
{ "nvim-telescope/telescope-media-files.nvim" },
|
||||
|
||||
-- Treesitter
|
||||
{
|
||||
|
|
|
@ -0,0 +1,44 @@
|
|||
return {
|
||||
"folke/snacks.nvim",
|
||||
priority = 9999,
|
||||
lazy = false,
|
||||
opts = {
|
||||
notifier = { enabled = true },
|
||||
dashboard = {
|
||||
preset = {
|
||||
pick = nil,
|
||||
---@type snacks.dashboard.Item[]
|
||||
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" },
|
||||
},
|
||||
header = [[
|
||||
|
||||
████ ██████ █████ ██
|
||||
███████████ █████
|
||||
█████████ ███████████████████ ███ ███████████
|
||||
█████████ ███ █████████████ █████ ██████████████
|
||||
█████████ ██████████ █████████ █████ █████ ████ █████
|
||||
███████████ ███ ███ █████████ █████ █████ ████ █████
|
||||
██████ █████████████████████ ████ █████ █████ ████ ██████
|
||||
]],
|
||||
},
|
||||
sections = {
|
||||
{ section = 'header' },
|
||||
{
|
||||
section = "keys",
|
||||
indent = 1,
|
||||
padding = 1,
|
||||
},
|
||||
{ section = 'recent_files', icon = ' ', title = 'Recent Files', indent = 3, padding = 2 },
|
||||
{ section = "startup" },
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
Loading…
Reference in New Issue