Drowning in email? Try Inbox Zero to learn sane tips for dealing with high-volume email. And don’t miss the free Inbox Zero video. »
Register for free on 43 Folders to comment on articles, post to our forum, customize your visits, and much more. Current users can login now.
| EXPLORE 43Folders | THE GOOD STUFF |
The past day I've been...
The past day I’ve been playing around with Vim’s folding functionality for the Big Ass Text File (BATF) and I’ve been pretty pleased with it. This might be what you’re looking for Merin. Type “:h folding” in Vim for more info. I’m using the marker method so I can port the file between work/home/school on my keychain drive and keep the same folding. Here’s how I have it set up:
@Home {{{1 Take car in for oil change Fix knob on dresser
@Calls {{{1 Call Karen Call Chad for his Birthday
etc… The {{{1 thingy marks the start of a fold. The number specifies the depth of the fold (I use one for all of them to make it easy). In command mode you can type za to toggle a fold open and closed. It will “fold” the text until the next {{{ thingy of the same level or a close thingy (“}}}” naturally). So if I type za in command mode anywhere under the @Home heading it will look like this:
+— 4 lines: @Home —— @Calls {{{1 Call Karen Call Chad for his Birthday
and if I close @Calls:
+— 4 lines: @Home —— +— 3 lines: @Calls
Entire sections can be moved around like they were single lines etc. It’s pretty cool. There are commands to open all (zR) and close all (zM) plus many more. Just remember you have to set the fold method:
:set foldmethod=marker