1
0
mirror of https://github.com/amix/vimrc synced 2025-07-13 14:55:01 +08:00

😼 Update plugins

This commit is contained in:
SUPERustam
2021-09-11 14:42:06 +03:00
parent 96bb75d663
commit e3b05f640b
61 changed files with 2215 additions and 830 deletions

View File

@ -33,6 +33,9 @@ au BufNewFile,BufRead Podfile,*.podspec call s:setf('ruby')
" Guard
au BufNewFile,BufRead Guardfile,.Guardfile call s:setf('ruby')
" Jb
au BufNewFile,BufRead *.jb call s:setf('ruby')
" Jbuilder
au BufNewFile,BufRead *.jbuilder call s:setf('ruby')

View File

@ -283,7 +283,7 @@ function! GetRubyIndent(...) abort
\ ]
" Most Significant line based on the previous one -- in case it's a
" contination of something above
" continuation of something above
let indent_info.plnum_msl = s:GetMSL(indent_info.plnum)
for callback_name in indent_callback_names

View File

@ -40,6 +40,12 @@ describe "Syntax highlighting" do
EOF
end
specify "magic comments - shareable_constant_value" do
assert_correct_highlighting <<~'EOF', 'shareable_constant_value', 'rubyMagicComment'
# shareable_constant_value: literal
EOF
end
specify "TODO comments" do
assert_correct_highlighting <<~'EOF', 'TODO', 'rubyTodo'
# TODO: turn off the oven

View File

@ -429,9 +429,10 @@ endif
" Comments and Documentation {{{1
syn match rubySharpBang "\%^#!.*" display
syn keyword rubyTodo FIXME NOTE TODO OPTIMIZE HACK REVIEW XXX todo contained
syn match rubyEncoding "[[:alnum:]-]\+" contained display
syn match rubyEncoding "[[:alnum:]-_]\+" contained display
syn match rubyMagicComment "\c\%<3l#\s*\zs\%(coding\|encoding\):" contained nextgroup=rubyEncoding skipwhite
syn match rubyMagicComment "\c\%<10l#\s*\zs\%(frozen_string_literal\|warn_indent\|warn_past_scope\):" contained nextgroup=rubyBoolean skipwhite
syn match rubyMagicComment "\c\%<10l#\s*\zs\%(shareable_constant_value\):" contained nextgroup=rubyEncoding skipwhite
syn match rubyComment "#.*" contains=@rubyCommentSpecial,rubySpaceError,@Spell
syn cluster rubyCommentSpecial contains=rubySharpBang,rubyTodo,rubyMagicComment