robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
e4137a7324
master
1" Vim filetype plugin file 2" Language: Zsh shell script 3" Maintainer: Christian Brabandt <cb@256bit.org> 4" Previous Maintainer: Nikolai Weibull <now@bitwi.se> 5" Latest Revision: 2026 Jul 23 6" License: Vim (see :h license) 7" Repository: https://github.com/chrisbra/vim-zsh 8 9if exists ( "b:did_ftplugin" ) 10finish 11endif 12let b: did_ftplugin = 1 13 14let s: cpo_save = & cpo 15set cpo & vim 16 17setlocal comments = :#commentstring = #\ %sformatoptions -= tformatoptions += croql 18 19let b: undo_ftplugin = "setl com< cms< fo< " 20 21if get ( g:, 'zsh_fold_enable' , 0 ) 22setlocal foldmethod = syntax 23let b: undo_ftplugin .= "fdm< " 24endif 25 26if executable ( 'zsh' ) && & shell !~# '/\%(nologin\|false\)$' 27if exists ( ':terminal' ) == 2 28command ! -buffer -nargs = 1 ZshKeywordPrg call term_start(['zsh', '-c', 'autoload -Uz run-help; run-help "$1"', '--', <q-args>]) 29elseif has ( "patch-9.2.0250" ) 30command ! -buffer -nargs = 1 ZshKeywordPrg echo system(['zsh', '-c', 'autoload -Uz run-help; MANPAGER= run-help "$1" 2>/dev/null', '--', <q-args>]) 31endif 32setlocal keywordprg = :ZshKeywordPrg 33let b: undo_ftplugin .= '| setl keywordprg< | sil! delc -buffer ZshKeywordPrg' 34 35if ! exists ( 'current_compiler' ) 36compiler zsh 37endif 38let b: undo_ftplugin .= ' | compiler make' 39endif 40 41let b: match_words = '\<if\>:\<elif\>:\<else\>:\<fi\>' 42 \. ',\<case\>:^\s*([^)]*):\<esac\>' 43 \. ',\<\%(select\|while\|until\|repeat\|for\%(each\)\=\)\>:\<done\>' 44let b: match_skip = 's:comment\|string\|heredoc\|subst' 45 46let & cpo = s: cpo_save 47unlet s: cpo_save