Vim is an extremely awesome tool for editing code, but with so many files in web applications, it can quickly become confusing to use. When you're trying to follow 4 or more files at a time, you may decide to leave files open even though you aren't really paying attention to them.
What we Want
What would be great to have is a way to bookmark files/folders, so that we can quickly go to them right when we need them without searching through hundreds of files/folders to find them.
Solution
NERDTree has a bunch of fantastic features, one of them being bookmarks. This is just their way of tagging files and allow you to quickly goto them when needed.
How to show the bookmarks section
To so the bookmarks section, just goto your NERDTree window and press Shift-B. This will toggle the bookmarks section, making it appear. If you want the bookmarks section to not be show, just hit Shift-B again.
How to create a Bookmark
To create a bookmark, just put your cursor over the file/folder you want to bookmark, then type and enter :Bookmark. This will create a bookmark in the bookmarks section. You can treat this as any other file/folder in NERDTree, and open it with "i" or "o".
How to Delete a Bookmark
To delete a bookmark, put your cursor over the file/folder you want to delete, then press Shift-D, then confirm by typing "y".
Conclusion
Bookmarks can make your programming experience much more enjoyable and is highly recommended over having a bunch of windows open at once
Resources
- http://dailyvim.tumblr.com/post/51238147680/nerdtree-bookmarks
NOTE: This guide is currently in rough draft form and could be improved with clearer instructions and pictures. If you would like it to be more in depth, I will be extremely happy to improve on this, all you need to do is ask in the comments and I will do it asap (I just don't want to spend forever on something no one reads and/or cares about).
No comments :
Post a Comment