Skip to content

A "sensible defaults" configuration for Vim. I'm primarily a PHP developer but these settings assume nothing. Instead, I tried to make a boilerplate setup that works for almost any environment.

sirlancelot/vim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sirlancelot's dot vimrc

Keeping things minimal yet convenient. Find out how to install it, then learn the key mappings. If you're on a Mac, get your terminal settings right. Find out what plugins I used. If you're feeling generous, you can even contribute.

installation

Install on Unix-based machines:

$ git clone --recursive https://github.com/sirlancelot/vim ~/.vim
$ ./extra/install.sh

You do not need to link gvimrc.vim as it is loaded at the bottom of vimrc.vim

Install on other platforms: just copy or link vimrc.vim to your home directory and call it .vimrc or _vimrc on Windows.

key mappings

Leader Key: , (comma)

  • Use <leader>ev and <leader>eg to edit vimrc and gvimrc respectively. They will be automatically reloaded when you save.
  • Hit <space> on a fold to toggle open or close. <s-space> is recursive.
  • <tab> will toggle 'list' which will visualize tabs and trailing whitespace.
  • <tab> and <s-tab> with a selection will indent and unindent, respectively.
  • <s-T> in normal mode will strip all trailing whitespace.

mac terminal settings

If the <Home> and <End> keys aren't working for you in Console Vim, you need to add the following changes to your Terminal Preferences Keyboard Settings:

  • Key: Home, Escape Sequence: \033OH
  • Key: End, Escape Sequence: \033OF

Note: \033 is typed by pressing <Escape> when the cursor is in the text box.

plugins used

All plugins are placed in the bundle/ subfolder and are git submodules. Each bundle is loaded using Pathogen. Rather than clutter up the .vim root folder, my personal additions have been placed either in the *vimrc.vim or personal/

contribute pull requests

Pull Requests will only be merged if they are based off the tip of the develop branch. Please rebase (don't merge!) your changes if you are behind. To learn about why rebase is better than merge, check out The Case for Git Rebase.

In short, to bring your Working Copy up to the tip of develop, you can use the rebase feature: git pull --rebase. See Pull with Rebase for details.

About

A "sensible defaults" configuration for Vim. I'm primarily a PHP developer but these settings assume nothing. Instead, I tried to make a boilerplate setup that works for almost any environment.

Resources

Stars

Watchers

Forks

Packages

No packages published