diff options
| author | Josh Rahm <joshuarahm@gmail.com> | 2024-11-19 22:57:13 +0000 |
|---|---|---|
| committer | Josh Rahm <joshuarahm@gmail.com> | 2024-11-19 22:57:13 +0000 |
| commit | 9be89f131f87608f224f0ee06d199fcd09d32176 (patch) | |
| tree | 11022dcfa9e08cb4ac5581b16734196128688d48 /runtime/ftplugin/typst.vim | |
| parent | ff7ed8f586589d620a806c3758fac4a47a8e7e15 (diff) | |
| parent | 88085c2e80a7e3ac29aabb6b5420377eed99b8b6 (diff) | |
| download | rneovim-9be89f131f87608f224f0ee06d199fcd09d32176.tar.gz rneovim-9be89f131f87608f224f0ee06d199fcd09d32176.tar.bz2 rneovim-9be89f131f87608f224f0ee06d199fcd09d32176.zip | |
Merge remote-tracking branch 'upstream/master' into mix_20240309
Diffstat (limited to 'runtime/ftplugin/typst.vim')
| -rw-r--r-- | runtime/ftplugin/typst.vim | 25 |
1 files changed, 19 insertions, 6 deletions
diff --git a/runtime/ftplugin/typst.vim b/runtime/ftplugin/typst.vim index c2d7811ace..895fc688d9 100644 --- a/runtime/ftplugin/typst.vim +++ b/runtime/ftplugin/typst.vim @@ -1,14 +1,27 @@ -" Vim filetype plugin -" Language: typst -" Maintainer: Riley Bruins <ribru17@gmail.com> -" Last Change: 2024 May 19 +" Vim filetype plugin file +" Language: Typst +" Maintainer: Gregory Anders +" Last Change: 2024 Oct 04 +" Based on: https://github.com/kaarmu/typst.vim if exists('b:did_ftplugin') finish endif let b:did_ftplugin = 1 -setlocal comments=sO:*\ -,mO:*\ \ ,exO:*/,s1:/*,mb:*,ex:*/,:// setlocal commentstring=//\ %s +setlocal comments=s1:/*,mb:*,ex:*/,:// +setlocal formatoptions+=croq +setlocal suffixesadd=.typ -let b:undo_ftplugin = 'setl com< cms<' +let b:undo_ftplugin = 'setl cms< com< fo< sua<' + +if get(g:, 'typst_conceal', 0) + setlocal conceallevel=2 + let b:undo_ftplugin .= ' cole<' +endif + +if !exists('current_compiler') + compiler typst + let b:undo_ftplugin ..= "| compiler make" +endif |