jdhao / jdhao.github.io

My personal blog: https://jdhao.github.io/
24 stars 6 forks source link

2022/02/27/nvim_file_tree_explorer/ #68

Open utterances-bot opened 2 years ago

utterances-bot commented 2 years ago

A Curated List of File Explorers for Nvim - jdhao's digital space

File explorer is one of the most widely-used types of plugin for Vim/Nvim. Below are my curated list of file explorers for Nvim. Some of these plugins are specifically written for Nvim and will not work for Vim.

https://jdhao.github.io/2022/02/27/nvim_file_tree_explorer/

cr3a7ure commented 2 years ago

My two cents here, netrw can do the basics and for someone who uses vim across machines is pretty handy.

" netrw configs
let g:netrw_banner = 0
let g:netrw_liststyle = 3
" Open file under cursor same window down
nnoremap <leader>oj :wincmd f<CR>
map <leader>oj :wincmd f<CR>

" Open file under cursor same window left
nnoremap <leader>ol :vertical wincmd f<CR>
map <leader>ol :vertical wincmd f<CR>

" Open file under cursor new window
nnoremap <leader>o<leader> :wincmd gf<CR>
map <leader>o<leader> :wincmd gf<CR>

" File Manager
" https://superuser.com/questions/31677/how-do-i-open-the-directory-of-the-current-open-file
map <leader>.j :Sex<CR>
map <leader>.h :Vex<CR>
map <leader>f. :30vs .<CR>

I like your work. Keep it up