robin/laufey
git clone https://git.robinwobin.dev/robin/laufey
7945732ed7
master
1" Elixir filetype plugin 2" Language: Elixir 3" Maintainer: Mitchell Hanberg <vimNOSPAM@mitchellhanberg.com> 4" Last Change: 2023 Dec 27 5" 2026 Jun 27 by Vim Project (add recommended style guard) 6 7if exists ( "b:did_ftplugin" ) 8finish 9endif 10let b: did_ftplugin = 1 11 12let s: save_cpo = & cpo 13set cpo & vim 14 15" Matchit support 16if exists ( 'loaded_matchit' ) && ! exists ( 'b:match_words' ) 17let b: match_ignorecase = 0 18 19let b: match_words = '\:\@<!\<\%(do\|fn\)\:\@!\>' . 20 \':' . 21 \'\<\%(else\|catch\|after\|rescue\)\:\@!\>' . 22 \':' . 23 \'\:\@<!\<end\>' . 24 \',{:},\[:\],(:)' 25endif 26 27if get ( g:, 'elixir_recommended_style' , 28 \get ( g:, 'filetype_recommended_style' , 1 )) 29setlocal shiftwidth = 2 softtabstop = 2 expandtab 30endif 31setlocal iskeyword += !,? 32setlocal comments = :# 33setlocal commentstring = #\ %s 34 35setlocal indentkeys = 0#,!^F,o,O 36" Enable keys for blocks 37setlocal indentkeys += 0=after,0=catch,0=do,0=else,0=end,0=rescue 38" Enable keys that are usually the first keys in a line 39setlocal indentkeys += 0->,0\|>,0},0],0),> 40 41let b: undo_ftplugin = 'setlocal sw< sts< et< isk< com< cms< indk<' 42 43let & cpo = s: save_cpo 44unlet s: save_cpo