Permalink
Browse files

Merge branch 'master' of github.com:rkneufeld/dotconfig

  • Loading branch information...
2 parents f56f6ee + 5b544b1 commit 73445cbbe31e18307a51b056bc2493a9f1e9c286 Ryan Neufeld committed Apr 10, 2012
Showing with 0 additions and 225 deletions.
  1. +0 −225 dotfiles/.vimrc
View
@@ -1,225 +0,0 @@
-" Use Vim settings, rather then Vi settings (much better!).
-" This must be first, because it changes other options as a side effect.
-set nocompatible
-
-" ============= My Stuff ============================
-" My additions
-
-map <Leader>s :setlocal spell spelllang=en_us
-" Have Q perform the last recorded macro
-map Q @@
-
-set directory^=$HOME/.vim_swap// "put all swap files together in one place
-
-let NERDTreeShowHidden = 0
-let NERDTreeMouseMode = 2
-let NERDTreeIgnore=['\.git','\.DS_Store']
-
-" make w! do sudo when required
-cmap w!! %!sudo tee > /dev/null %
-
-" Gist options
-let g:gist_clip_command = 'pbcopy'
-let g:gist_open_browser_after_post = 1
-
-" Fuzzy Finder Mappings
-map <C-t> :FufFileWithCurrentBufferDir<CR>
-map <C-b> :FufBuffer<CR>
-
-" MiniBuffer Explorer config
-let g:miniBufExplMapWindowNavVim = 1
-let g:miniBufExplUseSingleClick = 1
-
-" Pathogen
-runtime! autoload/pathogen.vim
-if exists('g:loaded_pathogen')
- call pathogen#runtime_prepend_subdirectories(expand('~/.vim/bundles'))
- call pathogen#helptags()
-end
-
-
-" ============= </My Stuff> ===========================
-
-" allow backspacing over everything in insert mode
-set backspace=indent,eol,start
-
-set nobackup
-set nowritebackup
-set history=1000 " keep 50 lines of command line history
-set ruler " show the cursor position all the time
-set showcmd " display incomplete commands
-set incsearch " do incremental searching
-
-" Switch syntax highlighting on, when the terminal has colors
-" Also switch on highlighting the last used search pattern.
-if (&t_Co > 2 || has("gui_running")) && !exists("syntax_on")
- syntax on
- set hlsearch
-
-endif
-
-colorscheme vividchalk
-if has('gui_running')
- " Color scheme
- highlight NonText guibg=#060606
- highlight Folded guibg=#0A0A0A guifg=#9090D0
-
-endif
-
-" Softtabs, 2 spaces
-set tabstop=2
-set shiftwidth=2
-set expandtab
-
-" Only do this part when compiled with support for autocommands.
-if has("autocmd")
-
- " Enable file type detection.
- " Use the default filetype settings, so that mail gets 'tw' set to 72,
- " 'cindent' is on in C files, etc.
- " Also load indent files, to automatically do language-dependent indenting.
- filetype plugin indent on
-
- " Put these in an autocmd group, so that we can delete them easily.
- augroup vimrcEx
- au!
-
- " For all text files set 'textwidth' to 78 characters.
- autocmd FileType text setlocal textwidth=78
-
- " When editing a file, always jump to the last known cursor position.
- " Don't do it when the position is invalid or when inside an event handler
- " (happens when dropping a file on gvim).
- autocmd BufReadPost *
- \ if line("'\"") > 0 && line("'\"") <= line("$") |
- \ exe "normal g`\"" |
- \ endif
-
- " In Gush workspace do not expand tabs
- autocmd! BufReadPost,BufNewFile */Gush.workspace/**/* setlocal noet
-
- augroup END
-else
-
- set autoindent " always set autoindenting on
-
-endif " has("autocmd")
-
-if has("folding")
- set foldenable
- set foldmethod=syntax
- set foldlevel=1
- set foldnestmax=2
- set foldtext=strpart(getline(v:foldstart),0,50).'\ ...\ '.substitute(getline(v:foldend),'^[\ #]*','','g').'\ '
-
- " automatically open folds at the starting cursor position
- autocmd BufReadPost .foldo!
-endif
-
-" Always display the status line
-set laststatus=2
-
-" \ is the leader character
-let mapleader = "\\"
-
-" Edit the README_FOR_APP (makes :R commands work)
-map <Leader>R :e doc/README_FOR_APP<CR>
-
-" Leader shortcuts for Rails commands
-map <Leader>m :Rmodel
-map <Leader>c :Rcontroller
-map <Leader>v :Rview
-map <Leader>u :Runittest
-map <Leader>f :Rfunctionaltest
-map <Leader>tm :RTmodel
-map <Leader>tc :RTcontroller
-map <Leader>tv :RTview
-map <Leader>tu :RTunittest
-map <Leader>tf :RTfunctionaltest
-map <Leader>sm :RSmodel
-map <Leader>sc :RScontroller
-map <Leader>sv :RSview
-map <Leader>su :RSunittest
-map <Leader>sf :RSfunctionaltest
-
-" Edit routes
-command! Rroutes :e config/routes.rb
-command! RTroutes :tabe config/routes.rb
-
-
-" Hide search highlighting
-map <Leader>h :set invhls <CR>
-
-" Opens an edit command with the path of the currently edited file filled in
-" Normal mode: <Leader>e
-map <Leader>e :e <C-R>=expand("%:p:h") . "/" <CR>
-
-" Opens a tab edit command with the path of the currently edited file filled in
-" Normal mode: <Leader>t
-map <Leader>te :tabe <C-R>=expand("%:p:h") . "/" <CR>
-
-" Inserts the path of the currently edited file into a command
-" Command mode: Ctrl+P
-cmap <C-P> <C-R>=expand("%:p:h") . "/" <CR>
-
-" Maps autocomplete to tab
-imap <Tab> <C-N>
-
-" Duplicate a selection
-" Visual mode: D
-vmap D y'>p
-
-" For Haml
-au! BufRead,BufNewFile *.haml setfiletype haml
-
-" No Help, please
-nmap <F1> <Esc>
-
-" Press ^F from insert mode to insert the current file name
-imap <C-F> <C-R>=expand("%")<CR>
-
-" Display extra whitespace
-set list listchars=tab:▸\ ,trail:·
-
-" Local config
-if filereadable(".vimrc.local")
- source .vimrc.local
-endif
-
-" Use Ack instead of Grep when available
-if executable("ack")
- set grepprg=ack\ -H\ --nogroup\ --nocolor
-endif
-
-
-" Numbers
-set number
-set numberwidth=4
-
-" Snippets are activated by Shift+Tab
-let g:snippetsEmu_key = "<S-Tab>"
-
-" Tab completion options
-" (only complete to the longest unambiguous match, and show a menu)
-set completeopt=longest,menu
-set wildmode=list:longest,list:full
-
-" case only matters with mixed case expressions
-set ignorecase
-set smartcase
-
-let g:indent_guides_enable_on_vim_startup = 1
-let g:indent_guides_start_level = 2
-let g:indent_guides_guide_size = 1
-"define :HighlightLongLines command to highlight the offending parts of
-"lines that are longer than the specified length (defaulting to 80)
-command! -nargs=? HighlightLongLines call s:HighlightLongLines('<args>')
-function! s:HighlightLongLines(width)
- let targetWidth = a:width != '' ? a:width : 79
- if targetWidth > 0
- exec 'match Todo /\%>' . (targetWidth) . 'v/'
- else
- echomsg "Usage: HighlightLongLines [natural number]"
- endif
-endfunction
-

0 comments on commit 73445cb

Please sign in to comment.