.config/nvim/after/ftplugin/markdown.vim@b0a0ba3240b5
.config/nvim/after/ftplugin/markdown.vim
Wed, 25 Sep 2024 15:03:13 -0500
- author
- Meredith Howard <mhoward@roomag.org>
- date
- Wed, 25 Sep 2024 15:03:13 -0500
- changeset 1179
- b0a0ba3240b5
- parent 1163
-
40367220022e
- permissions
- -rw-r--r--
No LSP autostart when read-only
I think nvim actually threw out 'view' argc detection, I just use -R and alias
view to it.
runtime ftplugin/text.vim
if !exists('b:markdown_autohtml')
let b:markdown_autohtml = 0
endif
function! s:autohtml() abort
if get(b:, 'markdown_autohtml', 0)
silent !md2html -o "%:p.html" "%:p"
endif
endfunction
augroup Markdown
autocmd!
autocmd BufWritePost <buffer> call s:autohtml()
augroup END