diff --git a/lazy-lock.json b/lazy-lock.json index 53e23a9..9a97a28 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -7,7 +7,6 @@ "conform.nvim": { "branch": "master", "commit": "3bad87250ed85246fe8c5bc10005ab5a6289ae4c" }, "friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" }, "gitsigns.nvim": { "branch": "main", "commit": "23ae90a2a52fdc9b8c50dc61d6c30ebb18521343" }, - "grug-far.nvim": { "branch": "main", "commit": "50d9ee2b5a19634670441948e7e4afaa042f1059" }, "gruvbox.nvim": { "branch": "main", "commit": "5e0a460d8e0f7f669c158dedd5f9ae2bcac31437" }, "harpoon": { "branch": "harpoon2", "commit": "ed1f853847ffd04b2b61c314865665e1dadf22c7" }, "lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" }, @@ -28,11 +27,11 @@ "mini.surround": { "branch": "main", "commit": "5aab42fcdcf31fa010f012771eda5631c077840a" }, "neogen": { "branch": "main", "commit": "d7f9461727751fb07f82011051338a9aba07581d" }, "neoscroll.nvim": { "branch": "master", "commit": "f957373912e88579e26fdaea4735450ff2ef5c9c" }, - "netrw.nvim": { "branch": "master", "commit": "90501c62b9b816ed3ed1e912ae9db9af5671a1b2" }, "nvim-autopairs": { "branch": "master", "commit": "23320e75953ac82e559c610bec5a90d9c6dfa743" }, "nvim-genghis": { "branch": "main", "commit": "cdf584d05ffc9d5c1f247079991552249e4f7487" }, "nvim-lint": { "branch": "master", "commit": "335a6044be16d7701001059cba9baa36fbeef422" }, "nvim-lspconfig": { "branch": "master", "commit": "336b388c272555d2ae94627a50df4c2f89a5e257" }, + "nvim-tree.lua": { "branch": "master", "commit": "321bc61580fd066b76861c32de3319c3a6d089e7" }, "nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }, "nvim-ts-autotag": { "branch": "main", "commit": "c4ca798ab95b316a768d51eaaaee48f64a4a46bc" }, "nvim-ts-context-commentstring": { "branch": "main", "commit": "1b212c2eee76d787bbea6aa5e92a2b534e7b4f8f" }, diff --git a/lua/core/options.lua b/lua/core/options.lua index 3c81753..30a5502 100644 --- a/lua/core/options.lua +++ b/lua/core/options.lua @@ -60,10 +60,8 @@ for k, v in pairs(options) do vim.opt[k] = v end --- netrw file explorer settings -vim.g.netrw_winsize = 20 -vim.g.netrw_banner = 0 -vim.g.netrw_liststyle = 1 +vim.g.loaded_netrw = 1 +vim.g.loaded_netrwPlugin = 1 vim.opt.path:append({ '**' }) vim.opt.shortmess:append({ W = true, I = true, c = true }) -- disable greeting diff --git a/lua/plugins/files.lua b/lua/plugins/files.lua index 880e571..648cac9 100644 --- a/lua/plugins/files.lua +++ b/lua/plugins/files.lua @@ -40,7 +40,24 @@ return { end, }, { - 'prichrd/netrw.nvim', - opts = {}, + 'nvim-tree/nvim-tree.lua', + version = '*', + lazy = false, + config = function() + require('nvim-tree').setup({ + sort = { + sorter = 'case_sensitive', + }, + view = { + width = 30, + }, + renderer = { + group_empty = true, + }, + filters = { + dotfiles = true, + }, + }) + end, }, } diff --git a/lua/plugins/whichkey.lua b/lua/plugins/whichkey.lua index 5a398bd..ef452d5 100644 --- a/lua/plugins/whichkey.lua +++ b/lua/plugins/whichkey.lua @@ -55,12 +55,14 @@ return { { 'e', group = ' Edit' }, { 'ea', ':b#', desc = 'Alternate File' }, - { 'ec', group = 'Edit Configs' }, + { 'ec', ':NvimTreeClose', desc = 'Close File Explorer' }, + { 'eC', group = 'Edit Configs' }, { 'ee', ':lua MiniFiles.open()', desc = 'Explore Tree' }, { 'eE', ':lua Snacks.explorer()', desc = 'File Explorer' }, { 'ef', 'gf', desc = 'File Under Cursor' }, { 'em', ':e README.md', desc = 'Readme' }, { 'en', ':enew', desc = 'New File' }, + { 'eo', ':NvimTreeOpen', desc = 'File Explorer' }, { 'er', ":lua require('snacks').rename.rename_file()", desc = 'Rename Current File' }, { 'f', group = ' Find' },