From c03cadc67b56f9bad094b9e87713b67272a9a0c1 Mon Sep 17 00:00:00 2001 From: Cody Hiar Date: Thu, 29 Mar 2018 10:31:26 -0600 Subject: Better markdown file support --- plugin/vim-options.vim | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'plugin') diff --git a/plugin/vim-options.vim b/plugin/vim-options.vim index 1ce38de..cb78947 100644 --- a/plugin/vim-options.vim +++ b/plugin/vim-options.vim @@ -45,6 +45,7 @@ autocmd FileType make setlocal tabstop=4 noexpandtab autocmd FileType scss setlocal tabstop=2 autocmd FileType ledger setlocal tabstop=2 autocmd FileType vim setlocal tabstop=2 +autocmd FileType mkd setlocal tw=80 " Make netrw prettier let g:netrw_banner = 0 " Hide the banner let g:netrw_liststyle = 3 " Tree view @@ -80,7 +81,7 @@ au BufNewFile,BufRead *.sls set filetype=yaml au BufNewFile,BufRead *.inc set filetype=php au BufNewFile,BufRead *.module set filetype=php au BufRead,BufNewFile *.ejs set syntax=htmljinja -au BufRead,BufNewFile *.md set filetype=markdown +au BufRead,BufNewFile *.md set filetype=markdown " Highligh current cursorline hi CursorLineNR cterm=bold ctermfg=226 " Status line colors per mode @@ -568,6 +569,15 @@ endif +"----------------------------------------------------------------------------------------------------------------------- +" Pencil (Markdown files +"----------------------------------------------------------------------------------------------------------------------- +if !empty(glob($EditorDir.'plugged/vim-pencil/plugin/pencil.vim')) + autocmd FileType markdown,mk call pencil#init({'wrap': 'hard'}) +endif +"----------------------------------------------------------------------------------------------------------------------- + + "----------------------------------------------------------------------------------------------------------------------- " Basic movements (h, j, k, l) require a number prefix. Break bad habits "----------------------------------------------------------------------------------------------------------------------- -- cgit v1.2.3