I've been wondering lately, if there is some kind of explorer for GVIM where I would see for example project in tree structure with its containing files, so I could easily navigate through them. If there would be some other functionality like projects in tabs on top with its own tree showing after switching project I would be even happier.

Thank you for help!

link|improve this question

feedback

4 Answers

up vote 0 down vote accepted

Not exactly, but I use a combination of gui file manager (Thunar), shell script, and Gvim remote control feature to achieve the same thing.

Basically:

$ cat ~/bin/cvim 
#!/bin/sh

if [ $# -gt 0 ] ; then
    exec gvim --servername CVIM --remote-silent "$@"
else
    exec gvim --servername CVIM
fi

The Cvim is a "common vim" that invokes gvim specially.

$ cat $HOME/.local/share/applications/cvim.desktop
[Desktop Entry]
Encoding=UTF-8
Name=cVim
Comment=Common vim - open in single vim instance.
Exec=cvim %F
Icon=gvim
Terminal=false
Type=Application
MimeType=text/*
Categories=Application;Development;

Set the GUI manager to use that App for text files.

Also in ~/.gvimrc:

map <M-Left> :bp<CR>
map <M-Right> :bn<CR>
map <M-Del> :bd<CR>
map ZZ :bd<CR>

And I think that should do it. Then you can just use your regular desktop file browser to look at your tree and select files, which causes a single instance of gvim to open in multiple buffers.

link|improve this answer
feedback

I haven't used it myself, but I've read good things about the project plugin, which allows you to "Organize/Navigate projects of files (like IDE/buffer explorer)".

link|improve this answer
feedback

You can look into the NERDTree plugin.

link|improve this answer
feedback

I have been searching for one plugin like this as well. NERDTree is my best choice for this kind of interaction. It is up to date for 7.3, very well configurable. No more half folded gVim or opening the Nautilus, Thunar or else to find my way around. :)

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.