Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Strip more gubbins from default vimrc.

  • Loading branch information...
commit e4ebd4cf05098849a1ed7ae081659b4c8da60e5b 1 parent e25ef2e
@nelstrom authored
Showing with 23 additions and 31 deletions.
  1. +23 −0 vim/plugin/vimrc-ex.vim
  2. +0 −31 vimrc
View
23 vim/plugin/vimrc-ex.vim
@@ -0,0 +1,23 @@
+" Only do this part when compiled with support for autocommands.
+if has("autocmd")
+ filetype plugin indent on
+
+ " Put these in an autocmd group, so that we can delete them easily.
+ augroup vimrcEx
+ au!
+
+ " 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).
+ " Also don't do it when the mark is in the first line, that is the default
+ " position when opening a file.
+ autocmd BufReadPost *
+ \ if line("'\"") > 1 && line("'\"") <= line("$") |
+ \ exe "normal! g`\"" |
+ \ endif
+
+ augroup END
+
+else
+ set autoindent " always set autoindenting on
+endif
View
31 vimrc
@@ -39,37 +39,6 @@ if &t_Co > 2 || has("gui_running")
set hlsearch
endif
-" Only do this part when compiled with support for autocommands.
-if has("autocmd")
- filetype plugin indent on
-
- " Put these in an autocmd group, so that we can delete them easily.
- augroup vimrcEx
- au!
-
- " 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).
- " Also don't do it when the mark is in the first line, that is the default
- " position when opening a file.
- autocmd BufReadPost *
- \ if line("'\"") > 1 && line("'\"") <= line("$") |
- \ exe "normal! g`\"" |
- \ endif
-
- augroup END
-
-else
- set autoindent " always set autoindenting on
-endif
-
-" Convenient command to see the difference between the current buffer and the
-" file it was loaded from, thus the changes you made.
-" Only define it when not defined already.
-if !exists(":DiffOrig")
- command DiffOrig vert new | set bt=nofile | r # | 0d_ | diffthis
- \ | wincmd p | diffthis
-endif
" Preferences {{{1
set visualbell t_vb=
Please sign in to comment.
Something went wrong with that request. Please try again.