Skip to content

Instantly share code, notes, and snippets.

@delonnewman
Created March 13, 2018 20:53
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save delonnewman/3d423ae14cb30112186cbf580bc71e7d to your computer and use it in GitHub Desktop.
Save delonnewman/3d423ae14cb30112186cbf580bc71e7d to your computer and use it in GitHub Desktop.
" General
set nocompatible
filetype on
filetype plugin on
filetype indent plugin on
set ofu=syntaxcomplete#Complete
set modeline
set history=1000
set clipboard+=unnamed
set ffs=unix,dos,mac
set viminfo+=!
" Teach Vim to Fish, will use 'sh' rather than fish for shelly things
if &shell =~# 'fish$'
set shell=sh
endif
" Pathogen
call pathogen#infect()
" Vundle
set rtp+=~/.vim/bundle/vundle/
call vundle#rc()
" Bundles
" General
Bundle "gmarik/vundle"
Bundle "tpope/vim-surround"
Bundle "taglist.vim"
Bundle "mileszs/ack.vim"
Bundle "vimwiki"
Bundle "altercation/vim-colors-solarized"
Bundle "tpope/vim-vinegar"
Bundle "ledger/vim-ledger"
Bundle "kien/ctrlp.vim"
Bundle "tpope/vim-dispatch"
Bundle "golden-ratio"
Bundle "rizzatti/dash.vim"
Bundle "ctrlpvim/ctrlp.vim"
Bundle "vim-airline/vim-airline"
Bundle "vim-airline/vim-airline-themes"
Bundle "scrooloose/syntastic"
Bundle "tpope/vim-projectionist"
Bundle "tpope/vim-endwise"
Bundle "majutsushi/tagbar"
" Fish
Bundle "dag/vim-fish"
" CSV
Bundle "csv.vim"
" Git
Bundle "tpope/vim-fugitive"
Bundle "airblade/vim-gitgutter"
" Perl
Bundle "vim-perl/vim-perl"
" Ruby
Bundle "tpope/vim-rails"
Bundle "tpope/vim-haml"
Bundle "tpope/vim-bundler"
Bundle "tpope/vim-rake"
Bundle "vim-ruby/vim-ruby"
" Markdown
Bundle "tpope/vim-markdown"
" Java/JVM
Bundle "tpope/vim-classpath"
" Clojure
Bundle "kien/rainbow_parentheses.vim"
Bundle "tpope/vim-leiningen"
Bundle "tpope/vim-fireplace"
Bundle "guns/vim-clojure-static"
Bundle "guns/vim-clojure-highlight"
" Lisps
Bundle "kien/rainbow_parentheses.vim"
au VimEnter * RainbowParenthesesToggle
au Syntax * RainbowParenthesesLoadRound
au Syntax * RainbowParenthesesLoadSquare
au Syntax * RainbowParenthesesLoadBraces
" Go
Bundle "fatih/vim-go"
" Racket
Bundle "scribble.vim"
Bundle "wlangstroth/vim-racket"
" Prolog
Bundle "mndrix/prolog.vim"
" JavaScript, etc.
Bundle "leafgarland/typescript-vim"
Bundle "vim-coffee-script"
Bundle "pangloss/vim-javascript"
" TypeScript tags
let g:tagbar_type_typescript = {
\ 'ctagsbin' : 'tstags',
\ 'ctagsargs' : '-f-',
\ 'kinds': [
\ 'e:enums:0:1',
\ 'f:function:0:1',
\ 't:typealias:0:1',
\ 'M:Module:0:1',
\ 'I:import:0:1',
\ 'i:interface:0:1',
\ 'C:class:0:1',
\ 'm:method:0:1',
\ 'p:property:0:1',
\ 'v:variable:0:1',
\ 'c:const:0:1',
\ ],
\ 'sort' : 0
\ }
" PHP
Bundle "vim-php/tagbar-phpctags.vim"
au FileType clojure RainbowParenthesesToggle
au FileType go set tabstop=4
au FileType go set softtabstop=4
au FileType go set shiftwidth=4
" Theme/Colors
set background=dark
syntax on
" Vim UI
set wildmenu
set ruler
set cmdheight=1
set number
set lz " do not redraw when running macros
set hid " change buf without saving
set backspace=2
set whichwrap+=<,>,h,l
set shortmess=atI
" Visual Cues
set mat=5 " rate of bracket blinkage (in tenths of a sec)
set nohlsearch " no hightligh for search phrases
set incsearch " but do highlight while searching
set so=10
"set statusline=%F%m%r%h%w\ \|\ format:%{&ff}\ \|\ type:%y\ \|\ ascii:\%03.3b\ \|\ l%4.4l,\ c%4.4v\ \|\ %3.3p%%\ \|\ len:%L
set laststatus=2 " always show the status line
" Tagbar
nmap <F8> :TagbarToggle<CR>
" For Git Gutter on Windows
let g:gitgutter_avoid_cmd_prompt_on_windows = 0
" Syntastic for JavaScript
let g:syntastic_javascript_checkers = ['jshint']
set listchars=tab:¬\ ,trail:·,eol:¶,extends:░,precedes:░,nbsp:·
" Text Formatting/Layout
set ai " autoindent
set si " smartindent
set cindent " c style indenting
set tabstop=2
set softtabstop=2
set shiftwidth=2
set expandtab
set wrap
set smarttab
" Python indent
au FileType python setlocal tabstop=4 expandtab shiftwidth=4 softtabstop=4
" Perl indent
au FileType perl setlocal tabstop=4 expandtab shiftwidth=4 softtabstop=4
" JavaScript
au FileType javascript setlocal tabstop=4 expandtab shiftwidth=4 softtabstop=4
" Boot files
au BufRead *.boot set filetype=clojure
" WonderScript files
au BufRead *.ws set filetype=clojure
au BufRead *.zera set filetype=clojure
au BufRead *.pb set filetype=clojure
au BufRead *.jelly set filetype=clojure
" Fish Shell
"au BufRead *.fish set filetype=sh
iab xdate <c-r>=strftime("%d/%m/%y %H:%M:%S")<cr>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment