Skip to content

Instantly share code, notes, and snippets.

@robinchew robinchew/.vimrc
Last active Aug 5, 2016

What would you like to do?
au! BufRead,BufNewFile *.module set filetype=php
au! BufRead,BufNewFile *.ctp set filetype=html
command W w
command E e
command SSFS syntax sync fromstart
noremap Q <Esc>
noremap q <Esc>
set iskeyword-=_
set iskeyword-=-
"au Syntax python source ~/.vim/syntax/mine.vim
hi Search ctermfg=White
"set list
"set listchars=tab:▸\ ,
set hlsearch
"Jump n lines and down the page without moving the cursor
nnoremap <PageUp> 10<C-y>
nnoremap <PageDown> 10<C-e>
"set clipboard=unnamedplus
let g:paredit_electric_return = 0
set backup
set swapfile
set backupdir=~/.vim-tmp
set directory=~/.vim-tmp
"execute pathogen#infect()
" Below is a piece of shit way to set indentations per file type
" because by default it will make all files of whatever type
" autoindent and autocomment.
"filetype plugin indent on
" Disable automatic comment insertion
" But does it even fucking work when 'filetype plugin indent on'
" is set? Read above.
"autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
" Most sensible way to set indentations per file type without
" the bullshit autoindent and autocommment for all file types by default.
autocmd FileType go setlocal shiftwidth=2 noexpandtab copyindent preserveindent softtabstop=0 shiftwidth=4 tabstop=4
"yy and p will copy and paste using system's clipboard
set clipboard=unnamedplus
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.