not really known
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

132 lines
2.8 KiB

  1. " sets spell check to be enabled to files which
  2. " end with either .md or .txt
  3. "
  4. " To get auto complete type z= when you are
  5. " over the word.
  6. autocmd BufRead,BufNewFile *.md setlocal spell spelllang=en_us
  7. autocmd BufRead,BufNewFile *.txt setlocal spell spelllang=en_us
  8. """ Indentation and Tabs """
  9. "file based indentation
  10. filetype plugin indent on
  11. "copy indentation from current line when making a new line
  12. set autoindent
  13. " Smart indentation when programming: indent after {
  14. set smartindent
  15. set tabstop=4 " number of spaces per tab
  16. set expandtab " convert tabs to spaces
  17. set shiftwidth=4 " set a tab press equal to 4 spaces
  18. """ Looks and Appearance"""
  19. " Enable syntax highlighting
  20. syntax enable
  21. try
  22. "color atomic-dark
  23. colorscheme desert
  24. catch
  25. endtry
  26. set background=dark
  27. " File Encodings
  28. " Set utf8 as standard encoding and en_US as the standard language
  29. set encoding=utf8
  30. " Use Unix as the standard file type
  31. set ffs=unix,dos,mac
  32. " Productivity
  33. " Set Line Numbers to show
  34. set number
  35. " Highlights the current line with a underscore
  36. set cursorline
  37. " Displays a red bar at 80 characters
  38. set colorcolumn=80
  39. " Shows a auto complete tab when you are typing a command
  40. " like :sp <tab>
  41. set wildmenu
  42. set wildignorecase
  43. " sets the size of the status bar at bottom to have a height of two
  44. set laststatus=2
  45. " Searching when in command mode type /words to find
  46. " search as characters are entered
  47. set incsearch
  48. " highlight matched characters
  49. set hlsearch
  50. " Ignore case when searching
  51. set ignorecase
  52. "Disable ding sound on error, flashes cursor instead
  53. set visualbell
  54. " Display ruler on bottom right -- should be there by default
  55. set ruler
  56. " Enables mouse support
  57. " Auto updates file if an external source edits the file
  58. set autoread
  59. " Maps jj in insertion mode to escape to make
  60. " switching between modes easier
  61. inoremap jj <ESC>
  62. " Improves performance by only redrawing screen when needed
  63. "set lazyredraw
  64. " Selection
  65. " v and arrows select characters
  66. " V select entire lines
  67. " Operations on selected text
  68. " d on something selected cuts it -- also used for delete
  69. " y = yank = copy
  70. " P paste before cursor
  71. " p paste after cursor
  72. " u undo
  73. " ctr r : redo
  74. " > shift text right
  75. " < shift test left
  76. " Basic Vim navigation
  77. " :sp file -- this will open a new file horizontally
  78. " :vsp file -- will open a file splitting vertically
  79. " ctrl-w w -- this will toggle to another open vim windo
  80. "
  81. "
  82. " Useful commands to memorize
  83. " Movement:
  84. " Ctr +f move forward a full screen
  85. " Ctr b move backwards a full screen
  86. "
  87. " gg : go to first line of document
  88. " G : go to last line of doucment
  89. "
  90. " 0 : go to start of line
  91. " $ : go to end of line
  92. " zz : center cursor on screen -- make current line half way on screen
  93. " } : jump to next paragraph
  94. " { : jump to last paragraph