aboutsummaryrefslogtreecommitdiffstats
path: root/lua/plugins/oil.lua
diff options
context:
space:
mode:
authorElvis Claros Castro <elvis@claros.ar>2024-08-23 09:40:05 -0300
committerElvis Claros Castro <elvis@claros.ar>2024-08-23 09:40:05 -0300
commit969aa6d3444f857c383b0e271febe087cd224349 (patch)
tree626929d795c5e4c262afb00570a87f3df0212fc3 /lua/plugins/oil.lua
parent59ab00e081d92db8760d65f3146f4156a962d5e4 (diff)
downloadnvim-conf-969aa6d3444f857c383b0e271febe087cd224349.tar.gz
nvim-conf-969aa6d3444f857c383b0e271febe087cd224349.zip
Feat: update
Diffstat (limited to 'lua/plugins/oil.lua')
-rw-r--r--lua/plugins/oil.lua15
1 files changed, 13 insertions, 2 deletions
diff --git a/lua/plugins/oil.lua b/lua/plugins/oil.lua
index 947876e..694fea9 100644
--- a/lua/plugins/oil.lua
+++ b/lua/plugins/oil.lua
@@ -5,7 +5,7 @@ return
-- Optional dependencies
dependencies = {
"nvim-tree/nvim-web-devicons",
- "ElvisClaros/oil-image-preview.nvim",
+ {"ElvisClaros/oil-image-preview.nvim", lazy = false},
},
config = function ()
@@ -60,7 +60,7 @@ return
-- Set to `false` to disable, or "name" to keep it on the file names
constrain_cursor = "editable",
-- Set to true to watch the filesystem for changes and reload oil
- experimental_watch_for_changes = false,
+ experimental_watch_for_changes = true,
-- Keymaps in oil buffer. Can be any value that `vim.keymap.set` accepts OR a table of keymap
-- options with a `callback` (e.g. { callback = function() ... end, desc = "", mode = "n" })
-- Additionally, if it is a string that matches "actions.<name>",
@@ -86,6 +86,17 @@ return
["g\\"] = "actions.toggle_trash",
["g<leader>"] = oip.openWithQuickLook,
["gp"] = oip.weztermPreview,
+ ["gdi"] = function()
+ require("oil").set_columns({ "icon", "", "", "" })
+ end,
+ ["gdf"] = function()
+ require("oil").set_columns({ "icon", "permissions", "size", "mtime" })
+ end,
+ ["g:"] = {
+ "actions.open_terminal",
+ desc = "Open terminal in current directory",
+ },
+
},
-- Configuration for the floating keymaps help window
keymaps_help = {