安装NERDTree

安装NERDTree

⑴、cd ~/.vim

⑵、git clone https://github.com/scrooloose/nerdtree

⑶、把plugin/NERD_tree.vim 和 doc/NERD_tree.txt 分别复制到 ~/.vim/plugin和~/.vim/doc

    cp nerdtree/plugin/NERD_tree.vim ~/.vim/plugin
    cp nerdtree/plugin/NERDTree.txt ~/.vim/doc

⑷、安装pathogen插件

   cd ~/.vim
   git clone https://gitcode.com/gh_mirrors/vi/vim-pathogen.git
   mkdir -p ~/.vim/autoload ~/.vim/bundle
   curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim
   mv nerdtree bundle/
   vim ~/.vimrc

在.vimrc中添加execute pathogen#infect()

打开Vim,输入 :NERDTree即可打开当前的目录树