29 Jan '17, 11pm

Optimise your use of VIM split screens

Most of us are Vim users and have tweaked our favorite editor for speed and convenience. See thoughtbot’s dotfiles . One of my favorite tools is the window split. Here is a quick splits overview and configurations to use them more effectively. Photo credit: Andrew Ressa on Flickr The basics Create a vertical split using :vsp and horizontal with :sp . By default, they duplicate the current buffer. This command also takes a filename: :vsp ~/.vimrc You can specify the new split height by prefixing with a number: :10sp ~/.zshrc Close the split like you would close vim: :q Easier split navigations We can use different key mappings for easy navigation between splits to save a keystroke. So instead of ctrl-w then j , it’s just ctrl-j : nnoremap <C-J> <C-W><C-J> nnoremap <C-K> <C-W><C-K> nnoremap <C-L> <C-W><C-L> nnoremap <C-H> <C-W><C-H> More natural split opening Open new split ...

Full article: https://robots.thoughtbot.com/vim-splits-move-faster-and-...

Tweets

How to Do 90% of What Plugins Do (With Just Vim)

robots.thoughtbot.com 20 Jan '17, 12am

From the August 2016 New York City Vim Meetup , Max Cantor explores tradeoffs between plugin complexity, and achieving sim...