Guest User

vimrc subset

a guest
Jul 26th, 2016
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
VIM 1.90 KB | None | 0 0
  1. "****************
  2. "AUTOCOMPLETE
  3. "****************
  4. Plugin 'ervandew/supertab'
  5. inoremap <tab> <c-n>
  6. inoremap <expr> <CR> pumvisible() ? "\<C-y>" : "\<C-g>u\<CR>"
  7. "set ofu=syntaxcomplete#Complete
  8.  
  9.  
  10. "*****************
  11. "FILETYPE OPTIONS
  12. "*****************
  13. " Identify filetypes for syntax colour use
  14. filetype plugin indent on
  15. filetype indent on
  16. filetype plugin on
  17. filetype on
  18. syntax on
  19.  
  20.  
  21. "*****************
  22. "MISC
  23. "*****************
  24.  
  25. " sudo write when you forgot sudo
  26. " from
  27. " https://www.reddit.com/r/linux/comments/mi80x/give_me_that_one_command_you_wish_you_knew_years/
  28. ca w!! w !sudo tee > /dev/null "%"
  29.  
  30. "fix paste between vims
  31. set clipboard=unnamed
  32.  
  33. "KILL WORD WRAP
  34. set wrap
  35. set linebreak
  36. set nolist  " list disables linebreak
  37. set textwidth=0
  38. set wrapmargin=0
  39.  
  40. "ALWAYS SHOW CURSORS POSITION
  41. set ruler
  42.  
  43. " When using the UI, space it out a little more (easier to read)
  44. set lsp=0
  45.  
  46. "Indicates input or replace mode at bottom
  47. set showmode
  48.  
  49. "SPELL CHECK ON
  50. set spell
  51.  
  52. "SHOW NEWLINES
  53. set list
  54.  
  55. " Show commands when tab is hit after pressing :
  56. set showcmd
  57.  
  58. "VISUAL BELL VS AUDIBLE BELL FOR ERRORS
  59. set visualbell
  60. "set novisualbell
  61.  
  62. " Do incremental searching.
  63. set incsearch
  64.  
  65. " Highlighted searches
  66. set hlsearch
  67.  
  68. " Keep 500 lines of command line history.
  69. set history=500
  70.  
  71. " make searches case-insensitive, unless they contain upper-case letters:
  72. set ignorecase
  73. set smartcase
  74.  
  75. "make backspace work
  76. set backspace=indent,eol,start
  77.  
  78. "tabs
  79. "CONVERT TABS TO SPACES
  80. set expandtab
  81. "tabs are always 3 spaces regardless of where they are in the file
  82. set smarttab
  83. set tabstop=4
  84. set softtabstop=4
  85. set shiftwidth=4
  86. "view tabs as a character
  87. set list
  88. set listchars=tab:>-
  89.  
  90. "IF IN A CODING BLOCK, AUTOMATICALLY INDENT
  91. "LIKE {
  92. "        CODE1
  93. " <auto> code2
  94. "     }
  95. set cindent
  96. set autoindent
  97.  
  98. " Shows the current status (insert, visual, ...) in statusline
  99. set showmode
Add Comment
Please, Sign In to add comment