make.vim 935 B

12345678910111213141516171819202122232425262728293031323334
  1. " Vim filetype plugin file
  2. " Language: Make
  3. " Maintainer: Bram Moolenaar <Bram@vim.org>
  4. " Last Change: 2013 Apr 22
  5. " Only do this when not done yet for this buffer
  6. if exists("b:did_ftplugin")
  7. finish
  8. endif
  9. let b:did_ftplugin = 1
  10. let b:undo_ftplugin = "setl et< sts< fo< com< cms< inc<"
  11. " Make sure a hard tab is used, required for most make programs
  12. setlocal noexpandtab softtabstop=0
  13. " Set 'formatoptions' to break comment lines but not other lines,
  14. " and insert the comment leader when hitting <CR> or using "o".
  15. setlocal fo-=t fo+=croql
  16. " Set 'comments' to format dashed lists in comments
  17. setlocal com=sO:#\ -,mO:#\ \ ,b:#
  18. " Set 'commentstring' to put the marker after a #.
  19. setlocal commentstring=#\ %s
  20. " Including files.
  21. let &l:include = '^\s*include'
  22. " For matchit.vim, suggested by Albert Netymk.
  23. if exists("loaded_matchit")
  24. let b:match_words = '\<if\(n\)\=\(eq\|def\)\>:\<else\>:\<endif\>,\<define\>:\<endef\>'
  25. endif