diff --git a/lua/lazy/plugins/cmdline.lua b/lua/lazy/plugins/cmdline.lua index 5d05b24..952ab90 100644 --- a/lua/lazy/plugins/cmdline.lua +++ b/lua/lazy/plugins/cmdline.lua @@ -1,13 +1,13 @@ return { - "folke/noice.nvim", - event = "VeryLazy", - dependencies = { - -- if you lazy-load any plugin below, make sure to add proper `module="..."` entries - "MunifTanjim/nui.nvim", - -- OPTIONAL: - -- `nvim-notify` is only needed, if you want to use the notification view. - -- If not available, we use `mini` as the fallback - "rcarriga/nvim-notify", + "folke/noice.nvim", + event = "VeryLazy", + dependencies = { + -- if you lazy-load any plugin below, make sure to add proper `module="..."` entries + "MunifTanjim/nui.nvim", + -- OPTIONAL: + -- `nvim-notify` is only needed, if you want to use the notification view. + -- If not available, we use `mini` as the fallback + "rcarriga/nvim-notify", }, config = function() require("noice").setup({ @@ -27,8 +27,20 @@ return { inc_rename = false, -- enables an input dialog for inc-rename.nvim lsp_doc_border = false, -- add a border to hover docs and signature help }, + -- 在这里添加或修改 routes 配置 + routes = { + { + filter = { + event = "msg_show", + kind = "emsg", + -- 使用这个错误信息中稳定且独特的片段作为过滤关键词 + find = "Error in decoration provider", + }, + -- opts.skip = true 会告诉 Noice 完全忽略这条消息 + opts = { skip = true }, + }, + -- ... 这里可能还有你其他的 routes 规则,或者没有 + }, }) - end + end, } - -