" <Nerdtree>-------------------{ ">> Basic settings letg:NERDTreeChDirMode = 2"Change current folder as root autocmd BufEnter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) |cd %:p:h |endif
">> UI settings let NERDTreeQuitOnOpen=1" Close NERDtree when files was opened let NERDTreeMinimalUI=1" Start NERDTree in minimal UI mode (No help lines) let NERDTreeDirArrows=1" Display arrows instead of ascii art in NERDTree let NERDTreeChDirMode=2" Change current working directory based on root directory in NERDTree letg:NERDTreeHidden=1" Don't show hidden files let NERDTreeWinSize=30" Initial NERDTree width let NERDTreeAutoDeleteBuffer = 1" Auto delete buffer deleted with NerdTree "let NERDTreeShowBookmarks=0 " Show NERDTree bookmarks let NERDTreeIgnore = ['\.pyc$', '\.swp', '\.swo', '__pycache__'] " Hide temp files in NERDTree "let g:NERDTreeShowLineNumbers=1 " Show Line Number " Open Nerdtree when there's no file opened "autocmd vimenter * if !argc()|NERDTree|endif " Or, auto-open Nerdtree "autocmd vimenter * NERDTree " Close NERDTree when there's no other windows autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif " Customize icons on Nerdtree letg:NERDTreeDirArrowExpandable = '▸' letg:NERDTreeDirArrowCollapsible = '▾'
ctrl + w + h 光标 focus 左侧树形目录 ctrl + w + l 光标 focus 右侧文件显示窗口 ctrl + w + w 光标自动在左右侧窗口切换 ctrl + w + r 移动当前窗口的布局位置
o 在已有窗口中打开文件、目录或书签,并跳到该窗口 go 在已有窗口 中打开文件、目录或书签,但不跳到该窗口 t 在新 Tab 中打开选中文件/书签,并跳到新 Tab T 在新 Tab 中打开选中文件/书签,但不跳到新 Tab i split 一个新窗口打开选中文件,并跳到该窗口 gi split 一个新窗口打开选中文件,但不跳到该窗口 s vsplit 一个新窗口打开选中文件,并跳到该窗口 gs vsplit 一个新 窗口打开选中文件,但不跳到该窗口 ! 执行当前文件 O 递归打开选中 结点下的所有目录 m 文件操作:复制、删除、移动等