set nocompatible filetype off set encoding=utf-8 "filetype plugin indent on " Settings set number syntax enable set background=dark set smartindent set tabstop=2 set shiftwidth=2 set expandtab set visualbell set noerrorbells " Set leader to comma let mapleader = "," let g:mapleader = "," let g:ansible_unindent_after_newline = 1 " Save via ',w' nmap w :w! nmap q :cq vmap , :w !pbcopy " QuickSave exit ,x nmap x :x " nmap p :set paste nmap N :noh nmap pp :set nopaste nmap n :set nu nmap nn :set nonu nnoremap j h nnoremap k l nnoremap c c nnoremap l j nnoremap h k nnoremap d nnoremap u nnoremap s :vsplit " Exit insert mode via ';j' imap ;j " CtrlP to open CtrlP " Ctrl-T to open highlighted file in new tab " Remove trailing spaces " Within PHP files autocmd BufWritePre *.php :%s/\s\+$//e " Open composer.json file easily " within a new tab via ',lc' nmap lc :tabe composer.json " Quick Ruby Run nmap r :! clear; ruby % " Remove folding of markdown " as per https://github.com/plasticboy/vim-markdown let g:vim_markdown_folding_disabled=1 " Airline on all the time set laststatus=2 " set autoindent set hlsearch set ignorecase set incsearch set linebreak set nolist set smartcase set title set wrap autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o