diff --git a/init.lua b/init.lua index 9119d6a..8c82dca 100644 --- a/init.lua +++ b/init.lua @@ -1,5 +1,3 @@ -require("bootstrap") - -- load options local options = require("options") @@ -8,6 +6,8 @@ for k, v in pairs(options.vim) do vim.opt[k] = v end +require("bootstrap") + -- apply color theme local status, _ = pcall(vim.cmd, "colorscheme " .. options.ui.theme) if not status then diff --git a/lua/keymap.lua b/lua/keymap.lua index eed25dd..804f1ad 100644 --- a/lua/keymap.lua +++ b/lua/keymap.lua @@ -79,8 +79,14 @@ return { }, { { "n" }, - "q", + "q", "BufferClose", + { desc = "Quit Buffer" }, + }, + { + { "n" }, + "q", + "quit", { desc = "Quit Window" }, }, { diff --git a/lua/plugins/dashboard.lua b/lua/plugins/dashboard.lua new file mode 100644 index 0000000..1262900 --- /dev/null +++ b/lua/plugins/dashboard.lua @@ -0,0 +1,94 @@ +local logo = [[ + __ _ _ + /\ \ \_ _| | ____ ___ _(_)_ __ ___ + / \/ / | | | |/ / _` \ \ / / | '_ ` _ \ +/ /\ /| |_| | < (_| |\ V /| | | | | | | +\_\ \/ \__,_|_|\_\__,_| \_/ |_|_| |_| |_| + +]] + +logo = string.rep("\n", 8) .. logo .. "\n\n" + +return { + { + "nvimdev/dashboard-nvim", + event = "VimEnter", + config = function() + require("dashboard").setup({ + theme = "doom", + shortcut_type = "letter", + hide = { + statusline = true, -- hide statusline default is true + tabline = true, -- hide the tabline + winbar = true, -- hide winbar + }, + config = { + header = vim.split(logo, "\n"), + center = { + { + action = "Telescope find_files", + desc = " Find File", + icon = " ", + key = "f", + }, + { + action = "ene | startinsert", + desc = " New File", + icon = " ", + key = "n", + }, + { + action = "Telescope oldfiles", + desc = " Recent Files", + icon = " ", + key = "r", + }, + { + action = "Telescope live_grep", + desc = " Find Text", + icon = " ", + key = "g", + }, + { + action = [[lua vim.cmd("cd ~/.config/nvim/") vim.cmd("Telescope fd")]], + desc = " Config", + icon = " ", + key = "c", + }, + { + action = 'lua require("persistence").load()', + desc = " Restore Session", + icon = " ", + key = "s", + }, + { + action = "Lazy", + desc = " Lazy", + icon = "󰒲 ", + key = "l", + }, + { + action = "Mason", + desc = " Language Server & Formatter", + icon = " ", + key = "m", + }, + { + action = "qa", + desc = " Quit", + icon = " ", + key = "q", + }, + }, + footer = function() + local stats = require("lazy").stats() + return { + "- loaded " .. stats.loaded .. "/" .. stats.count .. " plugins -", + } + end, + }, + }) + end, + dependencies = { { "nvim-tree/nvim-web-devicons" } }, + }, +} diff --git a/lua/plugins/mini.lua b/lua/plugins/mini.lua index 2d6ab6d..639ba60 100644 --- a/lua/plugins/mini.lua +++ b/lua/plugins/mini.lua @@ -12,13 +12,6 @@ return { }, }, }, - { - "echasnovski/mini.animate", - version = false, - config = function(_, opts) - require("mini.pairs").setup(opts) - end, - }, { "echasnovski/mini.pairs", version = false, diff --git a/lua/plugins/navic.lua b/lua/plugins/navic.lua index f8fb0a6..77575f1 100644 --- a/lua/plugins/navic.lua +++ b/lua/plugins/navic.lua @@ -20,6 +20,42 @@ return { }, opts = { attach_navic = false, + symbols = { + ---Modification indicator. + modified = "●", + ---Truncation indicator. + ellipsis = "...", + ---Entry separator. + separator = "", + }, + kinds = { + File = "󰈙", + Module = "", + Namespace = "󰌗", + Package = "", + Class = "󰌗", + Method = "󰆧", + Property = "", + Field = "", + Constructor = "", + Enum = "󰕘", + Interface = "󰕘", + Function = "󰊕", + Variable = "󰆧", + Constant = "󰏿", + String = "󰀬", + Number = "󰎠", + Boolean = "◩", + Array = "󰅪", + Object = "󰅩", + Key = "󰌋", + Null = "󰟢", + EnumMember = "", + Struct = "󰌗", + Event = "", + Operator = "󰆕", + TypeParameter = "󰊄", + }, }, }, } diff --git a/lua/plugins/notify.lua b/lua/plugins/notify.lua index 7cccd1c..e286e84 100644 --- a/lua/plugins/notify.lua +++ b/lua/plugins/notify.lua @@ -1,6 +1,8 @@ return { { "rcarriga/nvim-notify", - opts = {}, + opts = { + render = "wrapped-compact", + }, }, }