Guest User

Untitled

a guest
Jan 23rd, 2018
71
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.96 KB | None | 0 0
  1. set viminfo='20,\"500
  2. set ai sw=2 expandtab
  3. set title
  4. set hidden
  5. set nocompatible
  6. autocmd FileType * setlocal formatoptions-=c formatoptions-=r formatoptions-=o
  7. syntax on
  8.  
  9. " From Bram:
  10. " When editing a file, always jump to the last known cursor position.
  11. " Don't do it when the position is invalid or when inside an event handler
  12. " (happens when dropping a file on gvim).
  13. " DF - Also do not do this if the file resides in the $TEMP directory,
  14. " chances are it is a different file with the same name.
  15. " This comes from the $VIMRUNTIME/vimrc_example.vim file
  16. autocmd BufReadPost *
  17. \ if expand("<afile>:p:h") !=? $TEMP |
  18. \ if line("'\"") > 0 && line("'\"") <= line("$") |
  19. \ exe "normal g`\"" |
  20. \ let b:doopenfold = 1 |
  21. \ endif |
  22. \ endif
  23. " Need to postpone using "zv" until after reading the modelines.
  24. autocmd BufWinEnter *
  25. \ if exists("b:doopenfold") |
  26. \ unlet b:doopenfold |
  27. \ exe "normal zv" |
  28. \ endif
Add Comment
Please, Sign In to add comment