kickstart.nvim/lua/kickstart/plugins/oil.lua

31 lines
871 B
Lua

return {
{ -- Oil filesystem editor and explorer
'stevearc/oil.nvim',
dependencies = {
-- Useful for getting pretty icons, but requires a Nerd Font.
{ 'nvim-tree/nvim-web-devicons', enabled = vim.g.have_nerd_font },
},
config = function()
require('oil').setup {
columns = { 'icon' },
keymaps = {
['<C-h>'] = false,
['<M-h>'] = 'actions.select_split',
},
view_options = {
show_hidden = true,
},
}
-- Open parent directory in current window
vim.keymap.set('n', '-', '<CMD>Oil<CR>', { desc = 'Open parent directorv' })
-- Open parent directory in floating window
vim.keymap.set('n', '<space>-', require('oil').toggle_float)
end,
},
}
-- The line beneath this is called `modeline`. See `:help modeline`
-- vim: ts=2 sts=2 sw=2 et