Easily switch between your vim configuration and your pair's vim configuration.
First, install Vundle. Then install this plugin:
Bundle "gabebw/pear_shaped"
Let's say you're gabe, and you're pairing with ben.
First, copy both of your dotfiles to ~/.pear_shaped/gabe
and
~/.pear_shaped/ben
, respectively. Make sure there's a vimrc
file in both
directories, and that you can :source
them.
In vim:
:PearShaped ben
Now you're using ben's vim configuration. To switch back to gabe:
:PearShaped gabe
Neat-o.
You can also add two users and swap between them. Let's say you have ben and
gabe's vimrc
s set up like above. Now you can do:
:PearAdd gabe
:PearAdd ben
Since you added ben last, it's using his vimrc
. Now you can do :PearSwap
and
you'll be back to using gabe's vimrc, then :PearSwap
to go back to ben, etc.
If you want to pair with someone else, call :PearClearUsers
to clear the
users and then :PearAdd
the two new users.
This plugin will, in order:
- Clear all mappings
- Reset every option (set with
:set
) back to its default - Source the desired vimrc
If you want to put your configuration files somewhere other than
~/.pear_shaped
, you can change it:
let g:pear_shaped_directory = "~/.vim/pear_shaped"
rake
If you get errors on OSX about Vimrunner
, try installing MacVim then re-running the specs:
$ brew install macvim
Gabe Berke-Williams, 2011-present. Fueled by azuki cream pastries, thai iced tea, and (regarding vimscript) loathing.