diff --git a/lua/core/mappings.lua b/lua/core/mappings.lua index a0e4d1b..0ed79d3 100644 --- a/lua/core/mappings.lua +++ b/lua/core/mappings.lua @@ -95,6 +95,7 @@ M.customstuffs = { ["ra"] = { " call VrcQuery()", "Call REST endpoint" }, ["dl"] = { "0d$", "Delete line from start" }, ["gp"] = { " Git pull", "Git pull" }, + ["ga"] = { ":Git commit -a --amend --no-edit --no-verify", "Git commit -a --amend --no-edit --no-verify" }, ["gnb"] = { ":Git checkout -b ", "Checkout to a new branch" }, ["gri"] = { ":Git rebase -i HEAD~", "Git rebase interactive from HEAD" }, ["mkd"] = { "lua vim.api.nvim_create_user_command('PeekOpen', require('peek').open, {})", "Open markdown preview" }, @@ -112,8 +113,8 @@ M.customstuffs = { -- Mappings: TODO -- "trim(system('git branch --show-current 2>/dev/null'))" - -- ["tt"] = { ":call append(line('.') - 1, repeat(' ', indent('.')) . '# TODO-' . trim(system('git branch --show-current 2>/dev/null')) . ': ' . input('Comment >'))", "Add TODO comment + add to quickfix list" }, - ["tt"] = { ":call append(line('.') - 1, repeat(' ', indent('.')) . '# TODO: ' . input('Comment >'))", "Add TODO comment + add to quickfix list" }, + -- ["ct"] = { ":call append(line('.') - 1, repeat(' ', indent('.')) . '# TODO-' . trim(system('git branch --show-current 2>/dev/null')) . ': ' . input('Comment >'))", "Add TODO comment + add to quickfix list" }, + ["ct"] = { ":call append(line('.') - 1, repeat(' ', indent('.')) . '# TODO: ' . input('Comment >'))", "Add TODO comment + add to quickfix list" }, ["ww"] = { ":lua require('nvim-window').pick()", "Pick window to goto" }, ["wm"] = { ":WinShift", "Enter move window mode" }, @@ -381,6 +382,8 @@ M.telescope = { -- Diaglist: LSP diagnostics in quick/loc list ["dw"] = { "lua require('diaglist').open_all_diagnostics()", "Open all open buffers diagnostics in quickfix list" }, ["d0"] = { "lua require('diaglist').open_buffer_diagnostics()", "Open current buffer diagnostics in loclist list" }, + + [";"] = { " Telescope ", "Open Telescope" }, }, } diff --git a/lua/plugins/configs/noice.lua b/lua/plugins/configs/noice.lua new file mode 100644 index 0000000..a1cb474 --- /dev/null +++ b/lua/plugins/configs/noice.lua @@ -0,0 +1,46 @@ +local M = { + lsp = { + -- override markdown rendering so that **cmp** and other plugins use **Treesitter** + override = { + ["vim.lsp.util.convert_input_to_markdown_lines"] = true, + ["vim.lsp.util.stylize_markdown"] = true, + }, + }, + -- you can enable a preset for easier configuration + presets = { + bottom_search = true, -- use a classic bottom cmdline for search + command_palette = true, -- position the cmdline and popupmenu together + long_message_to_split = true, -- long messages will be sent to a split + inc_rename = false, -- enables an input dialog for inc-rename.nvim + lsp_doc_border = false, -- add a border to hover docs and signature help + }, + views = { + cmdline_popup = { + -- border = { + -- style = "none", + -- padding = { 2, 3 }, + -- }, + -- position = { + -- row = "85%", + -- col = "50%", + -- }, + size = { + width = 120, + height = "auto", + }, + }, + popupmenu = { + -- relative = "editor", + -- position = { + -- row = 25, + -- col = "50%", + -- }, + size = { + width = 120, + -- height = 10, + } + } + }, +} + +return M diff --git a/lua/plugins/init.lua b/lua/plugins/init.lua index 5d0de78..071807d 100644 --- a/lua/plugins/init.lua +++ b/lua/plugins/init.lua @@ -403,6 +403,17 @@ local default_plugins = { branch = "harpoon2", dependencies = { "nvim-lua/plenary.nvim" } }, + { + "folke/noice.nvim", + event = "VeryLazy", + opts = function() + return require "plugins.configs.noice" + end, + dependencies = { + "MunifTanjim/nui.nvim", + -- "rcarriga/nvim-notify", + }, + } } local config = require("core.utils").load_config()