From 56758415b40197ff1e7dab653ab24af58727aa4e Mon Sep 17 00:00:00 2001 From: Elvis Claros Castro Date: Sat, 17 Aug 2024 18:37:18 -0300 Subject: Feat: update all --- lua/plugins/completition.lua | 18 ++++++++++++------ lua/plugins/firenvim.lua | 19 +++++++++++++++++-- lua/plugins/mini.lua | 7 +++++++ lua/plugins/oil.lua | 11 +++++++++-- lua/plugins/smart-splits.lua | 8 ++++---- lua/plugins/which-key.lua | 26 ++++++++++++++------------ 6 files changed, 63 insertions(+), 26 deletions(-) create mode 100644 lua/plugins/mini.lua (limited to 'lua/plugins') diff --git a/lua/plugins/completition.lua b/lua/plugins/completition.lua index 7366d7a..ab65317 100644 --- a/lua/plugins/completition.lua +++ b/lua/plugins/completition.lua @@ -27,18 +27,24 @@ return { { "uga-rosa/cmp-dictionary", config = function() + local dict_fl = { + ["*"] = { "/usr/share/dict/words" }, + ft = { + foo = { "./../../spell/dict_es.dict" }, + }, + } local dict = require("cmp_dictionary") dict.setup({ -- The following are default values. + + paths = dict_fl["*"], exact_length = 2, first_case_insensitive = false, - document = false, - document_command = "wn %s -over", - sqlite = false, - max_number_items = -1, - -- capacity = 5, - debug = false, + -- document = { + -- enable = true, + -- command = { "wn", "${label}", "-over" }, + -- }, }) -- dict.switcher({ diff --git a/lua/plugins/firenvim.lua b/lua/plugins/firenvim.lua index 0b69060..d39627b 100644 --- a/lua/plugins/firenvim.lua +++ b/lua/plugins/firenvim.lua @@ -1,10 +1,25 @@ return { 'glacambre/firenvim', + build = ":call firenvim#install(0)", -- Lazy load firenvim -- Explanation: https://github.com/folke/lazy.nvim/discussions/463#discussioncomment-4819297 lazy = not vim.g.started_by_firenvim, - build = function() - vim.fn["firenvim#install"](0) + config = function() + vim.g.firenvim_config = { + localSettings = { + ['.*'] = { + cmdline = 'none', + priority = 0, + selector = 'textarea', + takeover = 'never', + }, + }, + } + vim.api.nvim_create_autocmd({'BufEnter'}, { + pattern = "github.com_*.txt", + command = "set filetype=markdown" + }) end } + diff --git a/lua/plugins/mini.lua b/lua/plugins/mini.lua new file mode 100644 index 0000000..3fa0493 --- /dev/null +++ b/lua/plugins/mini.lua @@ -0,0 +1,7 @@ +return { + 'echasnovski/mini.nvim', + dependencies = { + 'echasnovski/mini.icons', + }, + version = false +} diff --git a/lua/plugins/oil.lua b/lua/plugins/oil.lua index 58c0c13..947876e 100644 --- a/lua/plugins/oil.lua +++ b/lua/plugins/oil.lua @@ -3,8 +3,13 @@ return 'stevearc/oil.nvim', opts = {}, -- Optional dependencies - dependencies = { "nvim-tree/nvim-web-devicons" }, + dependencies = { + "nvim-tree/nvim-web-devicons", + "ElvisClaros/oil-image-preview.nvim", + }, config = function () + + local oip = require("oil-image-preview") require('oil').setup({ -- Oil will take over directory buffers (e.g. `vim .` or `:e src/`) -- Set to false if you still want to use netrw. @@ -25,7 +30,7 @@ return -- Window-local options to use for oil buffers win_options = { wrap = false, - signcolumn = "no", + signcolumn = "yes:3", cursorcolumn = false, foldcolumn = "0", spell = false, @@ -79,6 +84,8 @@ return ["gx"] = "actions.open_external", ["g."] = "actions.toggle_hidden", ["g\\"] = "actions.toggle_trash", + ["g"] = oip.openWithQuickLook, + ["gp"] = oip.weztermPreview, }, -- Configuration for the floating keymaps help window keymaps_help = { diff --git a/lua/plugins/smart-splits.lua b/lua/plugins/smart-splits.lua index 29cccb7..57faedb 100644 --- a/lua/plugins/smart-splits.lua +++ b/lua/plugins/smart-splits.lua @@ -3,28 +3,28 @@ return { config = true, keys = { { - "", + "", function() require("smart-splits").resize_left() end, desc = "Resize window left +10", }, { - "", + "", function() require("smart-splits").resize_down() end, desc = "Resize window down +10", }, { - "", + "", function() require("smart-splits").resize_up() end, desc = "Resize window up +10", }, { - "", + "", function() require("smart-splits").resize_right() end, diff --git a/lua/plugins/which-key.lua b/lua/plugins/which-key.lua index 50cd483..b9a47db 100644 --- a/lua/plugins/which-key.lua +++ b/lua/plugins/which-key.lua @@ -1,14 +1,16 @@ return { - 'folke/which-key.nvim', - event = 'VeryLazy', - keys = { - { - -- See: https://github.com/folke/which-key.nvim/issues/476 - desc = 'Workaround for which-key not showing up on ', - '', - function() require('which-key').show(vim.g.maplocalleader) end, - }, + "folke/which-key.nvim", + event = "VeryLazy", + opts = { + preset = "modern" + }, + keys = { + { + "?", + function() + require("which-key").show({ global = false }) + end, + desc = "Buffer Local Keymaps (which-key)", }, - opts = {}, - init = function() vim.opt.timeoutlen = 300 end, - } + }, +} -- cgit v1.2.3