This commit is contained in:
Adam Stankiewicz
2022-02-17 04:31:35 +01:00
parent 2c5af8f89d
commit b77c5f1107
42 changed files with 1855 additions and 1187 deletions

View File

@@ -177,7 +177,7 @@ On top of all language packs from [vim repository](https://github.com/vim/vim/tr
- [rust](https://github.com/rust-lang/rust.vim) (Rust syntax highlighting for rs and rs.in files) - [rust](https://github.com/rust-lang/rust.vim) (Rust syntax highlighting for rs and rs.in files)
- [scala](https://github.com/derekwyatt/vim-scala) (Scala syntax highlighting for scala, kojo and sc files) - [scala](https://github.com/derekwyatt/vim-scala) (Scala syntax highlighting for scala, kojo and sc files)
- [scss](https://github.com/cakebaker/scss-syntax.vim) (SCSS syntax highlighting for scss files) - [scss](https://github.com/cakebaker/scss-syntax.vim) (SCSS syntax highlighting for scss files)
- [sh](https://github.com/arzg/vim-sh) (Shell syntax highlighting for sh, bash, bats, cgi, command and 7 more files) - [sh](https://github.com/arzg/vim-sh) (Shell syntax highlighting for sh, bash, bats, cgi, command and 8 more files)
- [slim](https://github.com/slim-template/vim-slim) (Slim syntax highlighting for slim files) - [slim](https://github.com/slim-template/vim-slim) (Slim syntax highlighting for slim files)
- [slime](https://github.com/slime-lang/vim-slime-syntax) (Syntax highlighting for slime files) - [slime](https://github.com/slime-lang/vim-slime-syntax) (Syntax highlighting for slime files)
- [smt2](https://github.com/bohlender/vim-smt2) (SMT syntax highlighting for smt2 and smt files) - [smt2](https://github.com/bohlender/vim-smt2) (SMT syntax highlighting for smt2 and smt files)
@@ -206,7 +206,7 @@ On top of all language packs from [vim repository](https://github.com/vim/vim/tr
- [velocity](https://github.com/lepture/vim-velocity) (Syntax highlighting for vm files) - [velocity](https://github.com/lepture/vim-velocity) (Syntax highlighting for vm files)
- [vue](https://github.com/posva/vim-vue) (Vue syntax highlighting for vue and wpy files) - [vue](https://github.com/posva/vim-vue) (Vue syntax highlighting for vue and wpy files)
- [xdc](https://github.com/amal-khailtash/vim-xdc-syntax) (Syntax highlighting for xdc files) - [xdc](https://github.com/amal-khailtash/vim-xdc-syntax) (Syntax highlighting for xdc files)
- [xml](https://github.com/amadeus/vim-xml) (XML syntax highlighting for xml, adml, admx, ant, axml and 95 more files) - [xml](https://github.com/amadeus/vim-xml) (XML syntax highlighting for xml, adml, admx, ant, axaml and 96 more files)
- [xsl](https://github.com/vim-scripts/XSLT-syntax) (XSLT syntax highlighting for xslt and xsl files) - [xsl](https://github.com/vim-scripts/XSLT-syntax) (XSLT syntax highlighting for xslt and xsl files)
- [yard](https://github.com/noprompt/vim-yardoc) - [yard](https://github.com/noprompt/vim-yardoc)
- [zephir](https://github.com/xwsoul/vim-zephir) (Zephir syntax highlighting for zep files) - [zephir](https://github.com/xwsoul/vim-zephir) (Zephir syntax highlighting for zep files)

View File

@@ -46,7 +46,7 @@ if graphql#has_syntax_group('jsTemplateExpression')
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString' exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=jsTemplateExpression containedin=graphqlFold keepend syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=jsTemplateExpression containedin=graphqlFold keepend
syntax region graphqlTemplateString matchgroup=jsTemplateString start=+`#\s\{,4\}gql\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend syntax region graphqlTemplateString matchgroup=jsTemplateString start=+`#\s\{,4\}\(gql\|graphql\)\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend
hi def link graphqlTemplateString jsTemplateString hi def link graphqlTemplateString jsTemplateString
hi def link graphqlTaggedTemplate jsTaggedTemplate hi def link graphqlTaggedTemplate jsTaggedTemplate
@@ -60,7 +60,7 @@ elseif graphql#has_syntax_group('javaScriptStringT')
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString' exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=@javaScriptEmbededExpr containedin=graphqlFold keepend syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=@javaScriptEmbededExpr containedin=graphqlFold keepend
syntax region graphqlTemplateString matchgroup=javaScriptStringT start=+`#\s\{,4\}gql\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,javaScriptSpecial,javaScriptEmbed,@htmlPreproc extend syntax region graphqlTemplateString matchgroup=javaScriptStringT start=+`#\s\{,4\}\(gql\|graphql\)\>\s*$+ skip=+\\\\\|\\`+ end=+`+ contains=@GraphQLSyntax,javaScriptSpecial,javaScriptEmbed,@htmlPreproc extend
hi def link graphqlTemplateString javaScriptStringT hi def link graphqlTemplateString javaScriptStringT
hi def link graphqlTaggedTemplate javaScriptEmbed hi def link graphqlTaggedTemplate javaScriptEmbed

View File

@@ -46,6 +46,15 @@ exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlT
" Support expression interpolation ((${...})) inside template strings. " Support expression interpolation ((${...})) inside template strings.
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=typescriptTemplateSubstitution containedin=graphqlFold keepend syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=typescriptTemplateSubstitution containedin=graphqlFold keepend
" support #graphql , #gql comment strings
syntax region graphqlTemplateString
\ start=+`\(#\s\{,4\}\(gql\|graphql\)\)\@=+
\ skip=+\\\\\|\\`+
\ end=+`+me=s-1
\ containedin=typescriptTemplate
\ contained
\ contains=@GraphQLSyntax,typescriptTemplateSubstitution extend
hi def link graphqlTemplateString typescriptTemplate hi def link graphqlTemplateString typescriptTemplate
hi def link graphqlTemplateExpression typescriptTemplateSubstitution hi def link graphqlTemplateExpression typescriptTemplateSubstitution

View File

@@ -3,6 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'zinit', 'after/syntax/zsh.vim
endif endif
" Copyright (c) 2019 Sebastian Gniazdowski " Copyright (c) 2019 Sebastian Gniazdowski
" Copyright (c) 2021 Joakim Gottzén
" "
" Syntax highlighting for Zinit commands in any file of type `zsh'. " Syntax highlighting for Zinit commands in any file of type `zsh'.
" It adds definitions for the Zinit syntax to the ones from the " It adds definitions for the Zinit syntax to the ones from the
@@ -10,117 +11,163 @@ endif
" Main Zinit command. " Main Zinit command.
" Should be the only TOP rule for the whole syntax. " Should be the only TOP rule for the whole syntax.
syntax match ZinitCommand /\<zinit\>\s/me=e-1 syn match ZinitCommand '\(^\|\s\)zinit\s'ms=e-5,me=e-1 skipwhite
\ skipwhite \ nextgroup=ZinitCommand,ZinitIceCommand,ZinitPluginCommand,ZinitSnippetCommand,ZinitForCommand,ZinitContinue,ZinitIceWithParam,ZinitIce
\ nextgroup=ZinitSubCommands,ZinitPluginSubCommands,ZinitSnippetSubCommands
\ contains=ZinitSubCommands,ZinitPluginSubCommands,ZinitSnippetSubCommands
" TODO: add options for e.g. light syn match ZinitCommand '\s\%(help\|man\)\>'ms=s+1 skipwhite contained
syntax match ZinitSubCommands /\s\<\%(ice\|compinit\|env-whitelist\|cdreplay\|cdclear\|update\)\>\s/ms=s+1,me=e-1 syn match ZinitCommand '\s\%(unload\)\>'ms=s+1 skipwhite contained " load,light and snippet are handled elsewhere
\ contained syn match ZinitCommand '\s\%(clist\|completions\|cdisable\|cenable\|creinstall\|cuninstall\)\>'ms=s+1 skipwhite contained
syn match ZinitCommand '\s\%(csearch\|compinit\|cclear\|cdlist\|cdreplay\|cdclear\)\>'ms=s+1 skipwhite contained
syn match ZinitCommand '\s\%(dtrace\|dstart\|dstop\|dunload\|dreport\|dclear\)\>'ms=s+1 skipwhite contained
syn match ZinitCommand '\s\%(times\|zstatus\|report\|loaded\|list\|ls\|status\|recently\|bindkeys\)\>'ms=s+1 skipwhite contained
syn match ZinitCommand '\s\%(compile\|uncompile\|compiled\)\>'ms=s+1 skipwhite contained
syn match ZinitCommand '\s\%(self-update\|update\|delete\|cd\|edit\|glance\|stress\|changes\|create\)\>'ms=s+1 skipwhite contained
syn match ZinitCommand '\s\%(srv\|recall\|env-whitelist\|module\|add-fpath\|fpath\|run\)\>'ms=s+1 skipwhite contained
syntax match ZinitPluginSubCommands /\s\<\%(light\|load\)\>\s/ms=s+1,me=e-1 syn match ZinitIceCommand '\sice\s'ms=s+1,me=e-1 skipwhite contained nextgroup=ZinitIce,ZinitIceWithParam
\ skipwhite nextgroup=ZinitPlugin1,ZinitPlugin2,ZinitPlugin3
\ contains=ZinitPlugin1,ZinitPlugin2,ZinitPlugin3
syntax match ZinitSnippetSubCommands /\s\<\%(snippet\)\>\s/ms=s+1,me=e-1 syn match ZinitPluginCommand '\s\%(light\|load\)\s'ms=s+1,me=e-1 skipwhite contained nextgroup=ZinitPlugin,ZinitContinue
\ skipwhite
\ nextgroup=ZinitSnippetShorthands1,ZinitSnippetShorthands2
\ contains=ZinitSnippetShorthands1,ZinitSnippetShorthands2
" "user/plugin" syn match ZinitSnippetCommand '\s\%(snippet\)\s'ms=s+1,me=e-1 skipwhite contained nextgroup=ZinitSnippet,ZinitContinue
syntax match ZinitPlugin1 /\s["]\%([!-_]*\%(\/[!-_]\+\)\+\|[!-_]\+\)["]/ms=s+1,hs=s+2,he=e-1
\ contained
\ nextgroup=ZinitTrailingWhiteSpace
\ contains=ZinitTrailingWhiteSpace
" 'user/plugin' syn match ZinitForCommand '\sfor\s'ms=s+1,me=e-1 skipwhite contained
syntax match ZinitPlugin2 /\s[']\%([!-_]*\%(\/[!-_]\+\)\+\|[!-_]\+\)[']/ms=s+1,hs=s+2,he=e-1 \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
\ contained
\ nextgroup=ZinitTrailingWhiteSpace
\ contains=ZinitTrailingWhiteSpace
" user/plugin syn cluster ZinitLine contains=ZinitIce,ZinitIceWithParam,ZinitPlugin,ZinitSnippet,ZinitForCommand
syntax match ZinitPlugin3 /\s\%([!-_]*\%(\/[!-_]\+\)\+\|[!-_]\+\)/ms=s+1,me=e+2
\ contained
\ nextgroup=ZinitTrailingWhiteSpace
\ contains=ZinitTrailingWhiteSpace
" OMZ:: or PZT:: syn match ZinitContinue '\s\\\s*$'ms=s+1,me=s+2 skipwhite contained skipnl
" TODO: 'OMZ:: or 'PZT:: \ nextgroup=@ZinitLine
syntax match ZinitSnippetShorthands1 /\s\<\%(\%(OMZ\|PZT\)\>::\|\)/hs=s+1,he=e-2
\ contained
\ skipwhite
\ nextgroup=ZinitSnippetUrl1,ZinitSnippetUrl2
\ contains=ZinitSnippetUrl1,ZinitSnippetUrl2
" "OMZ:: or "PZT:: " user/plugin or @user/plugin
syntax match ZinitSnippetShorthands2 /\s["]\%(\%(OMZ\|PZT\)\>::\|\)/hs=s+2,he=e-2 syn match ZinitPlugin '\s@\?\<[a-zA-Z0-9][a-zA-Z0-9_\-]*\/[a-zA-Z0-9_\-\.]\+\>'ms=s+1 skipwhite contained
\ contained \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
\ skipwhite
\ nextgroup=ZinitSnippetUrl3,ZinitSnippetUrl4
\ contains=ZinitSnippetUrl3,ZinitSnippetUrl4
syntax match ZinitSnippetUrl3 /\<\%(http:\/\/\|https:\/\/\|ftp:\/\/\|\$HOME\|\/\)[!-_]\+\%(\/[!-_]\+\)*\/\?["]/he=e-1 " shorthands
\ contained syn match ZinitSnippet '\s\%(OMZ[LPT]\?\|PZT[M]\?\)::[a-zA-Z0-9_\-\.\/]\+\>'ms=s+1 skipwhite contained
\ nextgroup=ZinitTrailingWhiteSpace \ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
\ contains=ZinitTrailingWhiteSpace " url
syn match ZinitSnippet '\s\%(http[s]\?\|ftp\):\/\/[[:alnum:]%\/_#.-]*\>'ms=s+1 skipwhite contained
\ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
" "$VAR" local path
syn match ZinitSnippet +\s"\$\<[a-zA-Z0-9_]\+[^"]*"+ms=s+1 skipwhite contained
\ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
" "${VAR}" local path
syn match ZinitSnippet +\s"\${\<[a-zA-Z0-9_]\+}[^"]*"+ms=s+1 skipwhite contained
\ nextgroup=ZinitPlugin,ZinitSnippet,ZinitContinue
" TODO: Fix ZinitTrailingWhiteSpace not matching " ices which takes a param enclosed in "
syntax match ZinitSnippetUrl4 /\%(\%(OMZ\|PZT\)::\)[!-_]\+\%(\/[!-_]\+\)*\/\?["]/hs=s+5,he=e-1 syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(proto\|from\|ver\|bpick\|depth\|cloneopts\|pullopts\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ contained \ nextgroup=@ZinitLine,ZinitContinue
\ nextgroup=ZinitTrailingWhiteSpace \ contains=ZinitIceDoubleQuoteParam
\ contains=ZinitTrailingWhiteSpace syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(pick\|src\|multisrc\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceDoubleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wait\|load\|unload\|if\|has\|subscribe\|on-update-of\|trigger-load\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceDoubleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(mv\|cp\|atclone\|atpull\|atinit\|atload\|atdelete\|make\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceDoubleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(as\|id-as\|compile\|nocompile\|service\|bindmap\|wrap-track\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceDoubleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(extract\|subst\|autoload\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceDoubleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wrap\|ps-on-unload\|ps-on-update\)"+ skip=+\\"+ end=+"+ skipwhite contained
" http://… or https://… or ftp://… or $HOME/… or /… " zinit packages
" TODO: Fix $HOME/… and /… not matching syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(param\)"+ skip=+\\"+ end=+"+ skipwhite contained
syntax match ZinitSnippetUrl1 /\<\%(http:\/\/\|https:\/\/\|ftp:\/\/\|\$HOME\|\/\)[!-_]\+\%(\/[!-_]\+\)*\/\?/ \ nextgroup=@ZinitLine,ZinitContinue
\ contained \ contains=ZinitIceDoubleQuoteParam
\ nextgroup=ZinitTrailingWhiteSpace
\ contains=ZinitTrailingWhiteSpace
" TODO: Fix ZinitTrailingWhiteSpace not matching " added by the existing annexes
syntax match ZinitSnippetUrl2 /\<\%(\%(OMZ\|PZT\)::\)[!-_]\+\%(\/[!-_]\+\)*\/\?/hs=s+5 syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(fbin\|sbin\|gem\|node\|pip\|fmod\|fsrc\|ferc\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ contained \ nextgroup=@ZinitLine,ZinitContinue
\ nextgroup=ZinitTrailingWhiteSpace \ contains=ZinitIceDoubleQuoteParam
\ contains=ZinitTrailingWhiteSpace syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(dl\|patch\|submods\|cargo\|dlink\|dlink0\)"+ skip=+\\"+ end=+"+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceDoubleQuoteParam
syntax match ZinitTrailingWhiteSpace /[[:space:]]\+$/ contained syn match ZinitIceDoubleQuoteParam +[^"]*+ contained
" TODO: differentiate the no-value ices " ices that takes a param enclosed in '
" TODO: use contained syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(proto\|from\|ver\|bpick\|depth\|cloneopts\|pullopts\)'+ skip=+\\'+ end=+'+ skipwhite contained
syntax match ZinitIceSubCommand /\sice\s/ms=s+1,me=e-1 nextgroup=ZinitIceModifiers \ nextgroup=@ZinitLine,ZinitContinue
syntax match ZinitIceModifiers /\s\<\%(svn\|proto\|from\|teleid\|bindmap\|cloneopts\|id-as\|depth\|if\|wait\|load\)\>/ms=s+1 \ contains=ZinitIceSingleQuoteParam
syntax match ZinitIceModifiers /\s\<\%(unload\|blockf\|on-update-of\|subscribe\|pick\|bpick\|src\|as\|ver\|silent\)\>/ms=s+1 syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(pick\|src\|multisrc\)'+ skip=+\\'+ end=+'+ skipwhite contained
syntax match ZinitIceModifiers /\s\<\%(lucid\|notify\|mv\|cp\|atinit\|atclone\|atload\|atpull\|nocd\|run-atpull\|has\)\>/ms=s+1 \ nextgroup=@ZinitLine,ZinitContinue
syntax match ZinitIceModifiers /\s\<\%(cloneonly\|make\|service\|trackbinds\|multisrc\|compile\|nocompile\)\>/ms=s+1 \ contains=ZinitIceSingleQuoteParam
syntax match ZinitIceModifiers /\s\<\%(nocompletions\|reset-prompt\|wrap-track\|reset\|aliases\|sh\|bash\|ksh\|csh\)\>/ms=s+1 syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wait\|load\|unload\|if\|has\|subscribe\|on-update-of\|trigger-load\)'+ skip=+\\'+ end=+'+ skipwhite contained
syntax match ZinitIceModifiers /\s\<\%(\\!sh\|!sh\|\\!bash\|!bash\|\\!ksh\|!ksh\|\\!csh\|!csh\)\>/ms=s+1 \ nextgroup=@ZinitLine,ZinitContinue
syntax match ZinitIceModifiers /\s\<\%(blockf\|silent\|lucid\|trackbinds\|cloneonly\|nocd\|run-atpull\)\>/ms=s+1 \ contains=ZinitIceSingleQuoteParam
syntax match ZinitIceModifiers /\s\<\%(\|sh\|\!sh\|bash\|\!bash\|ksh\|\!ksh\|csh\|\!csh\)\>/ms=s+1 syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(mv\|cp\|atclone\|atpull\|atinit\|atload\|atdelete\|make\)'+ skip=+\\'+ end=+'+ skipwhite contained
syntax match ZinitIceModifiers /\s\<\%(nocompletions\|svn\|aliases\|trigger-load\)\>/ms=s+1 \ nextgroup=@ZinitLine,ZinitContinue
syntax match ZinitIceModifiers /\s\<\%(light-mode\|is-snippet\|countdown\|ps-on-unload\|ps-on-update\)\>/ms=s+1 \ contains=ZinitIceSingleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(as\|id-as\|compile\|nocompile\|service\|bindmap\|wrap-track\)'+ skip=+\\'+ end=+'+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceSingleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(extract\|subst\|autoload\)'+ skip=+\\'+ end=+'+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceSingleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(wrap\|ps-on-unload\|ps-on-update\)'+ skip=+\\'+ end=+'+ skipwhite contained
" Include also ices added by the existing annexes " zinit packages
syntax match ZinitIceModifiers /\s\<\%(test\|zman\|submod\|dl\|patch\|fbin\|sbin\|fsrc\|ferc\|fmod\|gem\|node\|rustup\|cargo\)\>/ms=s+1 syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(param\)'+ skip=+\\'+ end=+'+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceSingleQuoteParam
" Additional Zsh and Zinit functions " added by the existing annexes
syntax match ZshAndZinitFunctions /\<\%(compdef\|compinit\|zpcdreplay\|zpcdclear\|zpcompinit\|zpcompdef\)\>/ syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(fbin\|sbin\|gem\|node\|pip\|fmod\|fsrc\|ferc\)'+ skip=+\\'+ end=+'+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceSingleQuoteParam
syn region ZinitIceWithParam matchgroup=ZinitIce start=+\s\%(dl\|patch\|submods\|cargo\|dlink\|dlink0\)'+ skip=+\\'+ end=+'+ skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
\ contains=ZinitIceSingleQuoteParam
syn match ZinitIceSingleQuoteParam +[^']*+ contained
" ices that doens't take a param
syn match ZinitIce '\s\%(teleid\|svn\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s\%(wait\|cloneonly\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s\%(silent\|lucid\|notify\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s\%(blockf\|nocompletions\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s\%(run-atpull\|nocd\|make\|countdown\|reset\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s!\?\%(sh\|bash\|ksh\|csh\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s\%(id-as\|nocompile\|reset-prompt\|trackbinds\|aliases\|light-mode\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
syn match ZinitIce '\s\%(is-snippet\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
" ices that doens't take a param, from zinit packages
syn match ZinitIce '\s\%(pack\|git\|null\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
" ices that doens't take a param, added by the existing annexes
syn match ZinitIce '\s\%(notest\|rustup\|default-ice\|skip\|debug\)\>'ms=s+1 skipwhite contained
\ nextgroup=@ZinitLine,ZinitContinue
" additional Zsh and zinit functions
syn match ZshAndZinitFunctions '\<\%(compdef\|compinit\|zpcdreplay\|zpcdclear\|zpcompinit\|zpcompdef\)\>'
" highlights
hi def link ZinitCommand Statement
hi def link ZinitCommand Title
hi def link ZinitIceCommand Title
hi def link ZinitPluginCommand Title
hi def link ZinitSnippetCommand Title
hi def link ZinitForCommand zshRepeat
hi def link ZinitContinue Normal
hi def link ZinitPlugin Macro
hi def link ZinitSnippet Macro
hi def link ZinitIce Type
hi def link ZinitIceDoubleQuoteParam Special
hi def link ZinitIceSingleQuoteParam Special
hi def link ZshAndZinitFunctions Keyword
" Link
highlight def link ZshAndZinitFunctions Keyword
highlight def link ZinitCommand Statement
highlight def link ZinitSubCommands Title
highlight def link ZinitPluginSubCommands Title
highlight def link ZinitSnippetSubCommands Title
highlight def link ZinitIceModifiers Type
highlight def link ZinitSnippetShorthands1 Keyword
highlight def link ZinitSnippetShorthands2 Keyword
highlight def link ZinitPlugin1 Macro
highlight def link ZinitPlugin2 Macro
highlight def link ZinitPlugin3 Macro
highlight def link ZinitSnippetUrl1 Macro
highlight def link ZinitSnippetUrl2 Macro
highlight def link ZinitSnippetUrl3 Macro
highlight def link ZinitSnippetUrl4 Macro
highlight def link ZinitTrailingWhiteSpace Error

File diff suppressed because one or more lines are too long

View File

@@ -780,8 +780,7 @@ fu! csv#CalculateColumnWidth(row, silent) "{{{3
" row for the row for which to calculate the width " row for the row for which to calculate the width
let b:col_width=[] let b:col_width=[]
if has( 'vartabs' ) && b:delimiter == "\t" if has( 'vartabs' ) && b:delimiter == "\t"
let vts_save=&vts setlocal vts=
set vts=
endif endif
try try
if exists("b:csv_headerline") if exists("b:csv_headerline")
@@ -801,9 +800,6 @@ fu! csv#CalculateColumnWidth(row, silent) "{{{3
" delete buffer content in variable b:csv_list, " delete buffer content in variable b:csv_list,
" this was only necessary for calculating the max width " this was only necessary for calculating the max width
unlet! b:csv_list s:columnize_count s:decimal_column unlet! b:csv_list s:columnize_count s:decimal_column
if has( 'vartabs' ) && b:delimiter == "\t"
let &vts=vts_save
endif
endfu endfu
fu! csv#Columnize(field) "{{{3 fu! csv#Columnize(field) "{{{3
" Internal function, not called from external, " Internal function, not called from external,

View File

@@ -90,18 +90,6 @@ function! s:FindDartFmt() abort
return [] return []
endfunction endfunction
function! dart#analyzer(q_args) abort
call s:error('DartAnalyzer support has been removed. '.
\'If this broke your workflow please comment on '.
\'https://github.com/dart-lang/dart-vim-plugin/issues/89')
endfunction
function! dart#tojs(q_args) abort
call s:error('Dart2JS support has been removed. '.
\'If this broke your workflow please comment on '.
\'https://github.com/dart-lang/dart-vim-plugin/issues/89')
endfunction
" Finds the path to `uri`. " Finds the path to `uri`.
" "
" If the file is a package: uri, looks for a .packages file to resolve the path. " If the file is a package: uri, looks for a .packages file to resolve the path.

45
autoload/freebasic.vim Normal file
View File

@@ -0,0 +1,45 @@
if polyglot#init#is_disabled(expand('<sfile>:p'), 'freebasic', 'autoload/freebasic.vim')
finish
endif
" Vim filetype plugin file
" Language: FreeBASIC
" Maintainer: Doug Kearns <dougkearns@gmail.com>
" Last Change: 2021 Mar 16
" Dialects can be one of fb, qb, fblite, or deprecated
" Precedence is forcelang > #lang > lang
function! freebasic#GetDialect() abort
if exists("g:freebasic_forcelang")
return g:freebasic_forcelang
endif
if exists("g:freebasic_lang")
let dialect = g:freebasic_lang
else
let dialect = "fb"
endif
" override with #lang directive or metacommand
let skip = "has('syntax_items') && synIDattr(synID(line('.'), col('.'), 1), 'name') =~ 'Comment$'"
let pat = '\c^\s*\%(#\s*lang\s\+\|''\s*$lang\s*:\s*\)"\([^"]*\)"'
let save_cursor = getcurpos()
call cursor(1, 1)
let lnum = search(pat, 'n', '', '', skip)
call setpos('.', save_cursor)
if lnum
let word = matchlist(getline(lnum), pat)[1]
if word =~? '\%(fb\|deprecated\|fblite\|qb\)'
let dialect = word
else
echomsg "freebasic#GetDialect: Invalid lang, found '" .. word .. "' at line " .. lnum .. " " .. getline(lnum)
endif
endif
return dialect
endfunction
" vim: nowrap sw=2 sts=2 ts=8 noet fdm=marker:

View File

@@ -238,11 +238,7 @@ function! fsharp#loadConfig()
endif endif
if !exists('g:fsharp#fsautocomplete_command') if !exists('g:fsharp#fsautocomplete_command')
let s:fsac = fnamemodify(s:script_root_dir . "fsac/fsautocomplete.dll", ":p") let g:fsharp#fsautocomplete_command = ['fsautocomplete', '--background-service-enabled']
let g:fsharp#fsautocomplete_command =
\ ['dotnet', s:fsac,
\ '--background-service-enabled'
\ ]
endif endif
if !exists('g:fsharp#use_recommended_server_config') if !exists('g:fsharp#use_recommended_server_config')
let g:fsharp#use_recommended_server_config = 1 let g:fsharp#use_recommended_server_config = 1
@@ -283,6 +279,7 @@ function! fsharp#loadConfig()
" backend configuration " backend configuration
if g:fsharp#backend == 'languageclient-neovim' if g:fsharp#backend == 'languageclient-neovim'
let $DOTNET_ROLL_FORWARD='LatestMajor'
if !exists('g:LanguageClient_serverCommands') if !exists('g:LanguageClient_serverCommands')
let g:LanguageClient_serverCommands = {} let g:LanguageClient_serverCommands = {}
endif endif
@@ -478,8 +475,17 @@ function! fsharp#OnCursorMove()
endfunction endfunction
function! fsharp#showF1Help() function! fsharp#showF1Help()
let result = s:f1Help(expand('%:p'), line('.') - 1, col('.') - 1) function! s:callback_showF1Help(result)
echo result let result = a:result
if exists('result.result.content')
let content = json_decode(result.result.content)
if exists('content.Data')
let url = 'https://docs.microsoft.com/en-us/dotnet/api/' . substitute(content.Data, '#ctor', '-ctor', 'g')
echo url
endif
endif
endfunction
call s:f1Help(expand('%:p'), line('.') - 1, col('.') - 1, function("s:callback_showF1Help"))
endfunction endfunction
function! s:hover() function! s:hover()
@@ -505,39 +511,6 @@ function! fsharp#showTooltip()
endfunction endfunction
" FSAC update utils
function! s:update_win()
echom "[FSAC] Downloading FSAC. This may take a while..."
let script = s:script_root_dir . "install.ps1"
call system('powershell -ExecutionPolicy Unrestricted ' . script . " update")
endfunction
function! s:update_unix()
echom "[FSAC] Downloading FSAC. This may take a while..."
let zip = s:script_root_dir . "fsac.zip"
call system(
\ 'curl -fLo ' . zip . ' --create-dirs ' .
\ '"https://github.com/fsharp/FsAutoComplete/releases/latest/download/fsautocomplete.netcore.zip"'
\ )
if v:shell_error == 0
call system('unzip -o -d ' . s:script_root_dir . "/fsac " . zip)
call system('find ' . s:script_root_dir . '/fsac' . ' -type f -exec chmod 777 \{\} \;')
echom "[FSAC] Updated FsAutoComplete"
else
echom "[FSAC] Failed to update FsAutoComplete"
endif
endfunction
function! fsharp#updateFSAC(...)
if has('win32') && !has('win32unix')
call s:update_win()
else
call s:update_unix()
endif
endfunction
" FSI integration " FSI integration
let s:fsi_buffer = -1 let s:fsi_buffer = -1

File diff suppressed because it is too large Load Diff

View File

@@ -1957,7 +1957,7 @@ if !has_key(g:polyglot_is_disabled, 'slim')
endif endif
if !has_key(g:polyglot_is_disabled, 'sh') if !has_key(g:polyglot_is_disabled, 'sh')
au BufNewFile,BufRead *.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh,*.sh.in,*.tmux,*.tool,*/etc/udev/cdsymlinks.conf,{.,}bash_aliases,{.,}bash_history,{.,}bash_logout,{.,}bash_profile,{.,}bashrc,{.,}cshrc,{.,}env,{.,}env.example,{.,}flaskenv,{.,}kshrc,{.,}login,{.,}profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile setf sh au BufNewFile,BufRead *.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh,*.sh.in,*.tmux,*.tool,*.zsh-theme,*/etc/udev/cdsymlinks.conf,{.,}bash_aliases,{.,}bash_history,{.,}bash_logout,{.,}bash_profile,{.,}bashrc,{.,}cshrc,{.,}env,{.,}env.example,{.,}flaskenv,{.,}kshrc,{.,}login,{.,}profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile setf sh
au BufNewFile,BufRead *.zsh,*/etc/zprofile,{.,}zfbfmarks,{.,}zlogin,{.,}zlogout,{.,}zprofile,{.,}zshenv,{.,}zshrc setf zsh au BufNewFile,BufRead *.zsh,*/etc/zprofile,{.,}zfbfmarks,{.,}zlogin,{.,}zlogout,{.,}zprofile,{.,}zshenv,{.,}zshrc setf zsh
au BufNewFile,BufRead .zsh* call s:StarSetf('zsh') au BufNewFile,BufRead .zsh* call s:StarSetf('zsh')
au BufNewFile,BufRead .zlog* call s:StarSetf('zsh') au BufNewFile,BufRead .zlog* call s:StarSetf('zsh')
@@ -1985,7 +1985,7 @@ if !has_key(g:polyglot_is_disabled, 'rspec')
endif endif
if !has_key(g:polyglot_is_disabled, 'ruby') if !has_key(g:polyglot_is_disabled, 'ruby')
au BufNewFile,BufRead *.axlsx,*.builder,*.cap,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.opal,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rant,*.rb,*.rbi,*.rbuild,*.rbw,*.rbx,*.rjs,*.ru,*.ruby,*.rxml,*.spec,*.thor,*.watchr,{.,}Brewfile,{.,}Guardfile,{.,}autotest,{.,}irbrc,{.,}pryrc,{.,}simplecov,Appraisals,Berksfile,Buildfile,Capfile,Cheffile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,KitchenSink,Mavenfile,Podfile,Puppetfile,Rakefile,Routefile,Snapfile,Thorfile,Vagrantfile,[Rr]antfile,buildfile,vagrantfile setf ruby au BufNewFile,BufRead *.axlsx,*.builder,*.cap,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.opal,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rant,*.rb,*.rbi,*.rbuild,*.rbw,*.rbx,*.rjs,*.ru,*.ruby,*.rxml,*.spec,*.thor,*.watchr,{.,}Brewfile,{.,}Guardfile,{.,}autotest,{.,}irbrc,{.,}pryrc,{.,}simplecov,Appraisals,Berksfile,Buildfile,Capfile,Cheffile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,KitchenSink,Mavenfile,Podfile,Puppetfile,Rakefile,Routefile,Snapfile,Steepfile,Thorfile,Vagrantfile,[Rr]antfile,buildfile,vagrantfile setf ruby
au BufNewFile,BufRead [Rr]akefile* call s:StarSetf('ruby') au BufNewFile,BufRead [Rr]akefile* call s:StarSetf('ruby')
au BufNewFile,BufRead *.erb,*.erb.deface,*.rhtml setf eruby au BufNewFile,BufRead *.erb,*.erb.deface,*.rhtml setf eruby
endif endif
@@ -2577,7 +2577,7 @@ if !has_key(g:polyglot_is_disabled, 'ant')
endif endif
if !has_key(g:polyglot_is_disabled, 'xml') if !has_key(g:polyglot_is_disabled, 'xml')
au BufNewFile,BufRead *.adml,*.admx,*.ant,*.axml,*.builds,*.ccproj,*.ccxml,*.cdxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.csproj.user,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.tpm,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wpl,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*/etc/blkid.tab,*/etc/blkid.tab.old,*/etc/xdg/menus/*.menu,*fglrxrc,{.,}classpath,{.,}cproject,{.,}project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config setf xml au BufNewFile,BufRead *.adml,*.admx,*.ant,*.axaml,*.axml,*.builds,*.ccproj,*.ccxml,*.cdxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.csproj.user,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.tpm,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wpl,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*/etc/blkid.tab,*/etc/blkid.tab.old,*/etc/xdg/menus/*.menu,*fglrxrc,{.,}classpath,{.,}cproject,{.,}project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config setf xml
endif endif
if !has_key(g:polyglot_is_disabled, 'csv') if !has_key(g:polyglot_is_disabled, 'csv')

View File

@@ -460,7 +460,7 @@ let s:globs = {
\ 'rrst': '*.rrst,*.srst', \ 'rrst': '*.rrst,*.srst',
\ 'rst': '*.rst,*.rest,*.rest.txt,*.rst.txt', \ 'rst': '*.rst,*.rest,*.rest.txt,*.rst.txt',
\ 'rtf': '*.rtf', \ 'rtf': '*.rtf',
\ 'ruby': '*.rb,*.builder,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rbi,*.rbuild,*.rbw,*.rbx,*.ru,*.ruby,*.spec,*.thor,*.watchr,*.rxml,*.rjs,*.rant,*.axlsx,*.cap,*.opal,.irbrc,.pryrc,.simplecov,Appraisals,Berksfile,Buildfile,Capfile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,Mavenfile,Podfile,Puppetfile,Rakefile,Snapfile,Thorfile,Vagrantfile,buildfile,[Rr]antfile,.autotest,Cheffile,KitchenSink,Routefile,.Guardfile,.Brewfile,vagrantfile,[Rr]akefile*,*_spec.rb', \ 'ruby': '*.rb,*.builder,*.eye,*.fcgi,*.gemspec,*.god,*.jbuilder,*.mspec,*.pluginspec,*.podspec,*.prawn,*.rabl,*.rake,*.rbi,*.rbuild,*.rbw,*.rbx,*.ru,*.ruby,*.spec,*.thor,*.watchr,*.rxml,*.rjs,*.rant,*.axlsx,*.cap,*.opal,.irbrc,.pryrc,.simplecov,Appraisals,Berksfile,Buildfile,Capfile,Dangerfile,Deliverfile,Fastfile,Gemfile,Guardfile,Jarfile,Mavenfile,Podfile,Puppetfile,Rakefile,Snapfile,Steepfile,Thorfile,Vagrantfile,buildfile,[Rr]antfile,.autotest,Cheffile,KitchenSink,Routefile,.Guardfile,.Brewfile,vagrantfile,[Rr]akefile*,*_spec.rb',
\ 'rust': '*.rs,*.rs.in', \ 'rust': '*.rs,*.rs.in',
\ 'samba': 'smb.conf', \ 'samba': 'smb.conf',
\ 'sas': '*.sas', \ 'sas': '*.sas',
@@ -480,7 +480,7 @@ let s:globs = {
\ 'services': '', \ 'services': '',
\ 'setserial': '', \ 'setserial': '',
\ 'sexplib': '*.sexp', \ 'sexplib': '*.sexp',
\ 'sh': '*.sh,*.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh.in,*.tmux,*.tool,.bash_aliases,.bash_history,.bash_logout,.bash_profile,.bashrc,.cshrc,.env,.env.example,.flaskenv,.kshrc,.login,.profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile', \ 'sh': '*.sh,*.bash,*.bats,*.cgi,*.command,*.env,*.fcgi,*.ksh,*.sh.in,*.tmux,*.tool,*.zsh-theme,.bash_aliases,.bash_history,.bash_logout,.bash_profile,.bashrc,.cshrc,.env,.env.example,.flaskenv,.kshrc,.login,.profile,9fs,PKGBUILD,bash_aliases,bash_logout,bash_profile,bashrc,cshrc,gradlew,kshrc,login,man,profile',
\ 'sieve': '*.siv,*.sieve', \ 'sieve': '*.siv,*.sieve',
\ 'sil': '*.sil', \ 'sil': '*.sil',
\ 'simula': '*.sim', \ 'simula': '*.sim',
@@ -611,7 +611,7 @@ let s:globs = {
\ 'xhtml': '*.xhtml,*.xht', \ 'xhtml': '*.xhtml,*.xht',
\ 'xinetd': '', \ 'xinetd': '',
\ 'xmath': '*.msc,*.msf', \ 'xmath': '*.msc,*.msf',
\ 'xml': '*.xml,*.adml,*.admx,*.ant,*.axml,*.builds,*.ccproj,*.ccxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*.cdxml,*.tpm,*.csproj.user,*.wpl,.classpath,.cproject,.project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config,*fglrxrc', \ 'xml': '*.xml,*.adml,*.admx,*.ant,*.axaml,*.axml,*.builds,*.ccproj,*.ccxml,*.clixml,*.cproject,*.cscfg,*.csdef,*.csl,*.csproj,*.ct,*.depproj,*.dita,*.ditamap,*.ditaval,*.dll.config,*.dotsettings,*.filters,*.fsproj,*.fxml,*.glade,*.gml,*.gmx,*.grxml,*.gst,*.hzp,*.iml,*.ivy,*.jelly,*.jsproj,*.kml,*.launch,*.mdpolicy,*.mjml,*.mod,*.mxml,*.natvis,*.ncl,*.ndproj,*.nproj,*.nuspec,*.odd,*.osm,*.pkgproj,*.pluginspec,*.proj,*.props,*.psc1,*.pt,*.rdf,*.res,*.resx,*.rss,*.sch,*.scxml,*.sfproj,*.shproj,*.srdf,*.storyboard,*.sublime-snippet,*.targets,*.tml,*.ui,*.urdf,*.ux,*.vbproj,*.vcxproj,*.vsixmanifest,*.vssettings,*.vstemplate,*.vxml,*.wixproj,*.workflow,*.wsdl,*.wsf,*.wxi,*.wxl,*.wxs,*.x3d,*.xacro,*.xaml,*.xib,*.xlf,*.xliff,*.xmi,*.xml.dist,*.xmp,*.xproj,*.xsd,*.xspec,*.xul,*.zcml,*.cdxml,*.tpm,*.csproj.user,*.wpl,.classpath,.cproject,.project,App.config,NuGet.config,Settings.StyleCop,Web.Debug.config,Web.Release.config,Web.config,packages.config,*fglrxrc',
\ 'xml.twig': '*.xml.twig', \ 'xml.twig': '*.xml.twig',
\ 'xmodmap': '*Xmodmap,*xmodmap*', \ 'xmodmap': '*Xmodmap,*xmodmap*',
\ 'xpm': '*.xpm,*.pm', \ 'xpm': '*.xpm,*.pm',

View File

@@ -56,7 +56,17 @@ function! unison#Complete(findstart, base) abort
" locate the start of the word " locate the start of the word
let line = getline('.') let line = getline('.')
let start = col('.') - 1 let start = col('.') - 1
while start > 0 && line[start - 1] !~ '\s' && line[start - 1] != '(' && line[start - 1] != ')' " Examples of where we want to count the start of a word:
"
" foo List.fold<cursor>
" ^
"
" {Abor<cursor>
" ^
"
" (List.fol<cursor>
" ^
while start > 0 && line[start - 1] !~ '\v\s|[(){}\[\]]'
let start -= 1 let start -= 1
endwhile endwhile
return start return start

View File

@@ -7,6 +7,7 @@ endif
" Maintainer: Markus Mottl <markus.mottl@gmail.com> " Maintainer: Markus Mottl <markus.mottl@gmail.com>
" URL: https://github.com/ocaml/vim-ocaml " URL: https://github.com/ocaml/vim-ocaml
" Last Change: " Last Change:
" 2021 Nov 03 - Improved error format (Jules Aguillon)
" 2020 Mar 28 - Improved error format (Thomas Leonard) " 2020 Mar 28 - Improved error format (Thomas Leonard)
" 2017 Nov 26 - Improved error format (Markus Mottl) " 2017 Nov 26 - Improved error format (Markus Mottl)
" 2013 Aug 27 - Added a new OCaml error format (Markus Mottl) " 2013 Aug 27 - Added a new OCaml error format (Markus Mottl)
@@ -39,10 +40,13 @@ CompilerSet errorformat =
\%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d:, \%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d:,
\%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d\ %.%#, \%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d\ %.%#,
\%EFile\ \"%f\"\\,\ line\ %l\\,\ character\ %c:%m, \%EFile\ \"%f\"\\,\ line\ %l\\,\ character\ %c:%m,
\%EFile\ \"%f\"\\,\ line\ %l:,
\%+EReference\ to\ unbound\ regexp\ name\ %m, \%+EReference\ to\ unbound\ regexp\ name\ %m,
\%Eocamlyacc:\ e\ -\ line\ %l\ of\ \"%f\"\\,\ %m, \%Eocamlyacc:\ e\ -\ line\ %l\ of\ \"%f\"\\,\ %m,
\%Wocamlyacc:\ w\ -\ %m, \%Wocamlyacc:\ w\ -\ %m,
\%-Zmake%.%#, \%-Zmake%.%#,
\%C%*\\d\ \|%.%#,
\%C%p^%#,
\%C%m, \%C%m,
\%D%*\\a[%*\\d]:\ Entering\ directory\ `%f', \%D%*\\a[%*\\d]:\ Entering\ directory\ `%f',
\%X%*\\a[%*\\d]:\ Leaving\ directory\ `%f', \%X%*\\a[%*\\d]:\ Leaving\ directory\ `%f',
@@ -54,7 +58,9 @@ CompilerSet errorformat =
\%X%*\\a:\ Leaving\ directory\ '%f', \%X%*\\a:\ Leaving\ directory\ '%f',
\%DEntering\ directory\ '%f', \%DEntering\ directory\ '%f',
\%XLeaving\ directory\ '%f', \%XLeaving\ directory\ '%f',
\%DMaking\ %*\\a\ in\ %f \%DMaking\ %*\\a\ in\ %f,
\%+G%m
let &cpo = s:cpo_save let &cpo = s:cpo_save
unlet s:cpo_save unlet s:cpo_save

View File

@@ -1,7 +1,7 @@
" Vim support file to detect file types " Vim support file to detect file types
" "
" Maintainer: Bram Moolenaar <Bram@vim.org> " Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2021 Dec 27 " Last Change: 2022 Jan 31
" Listen very carefully, I will say this only once " Listen very carefully, I will say this only once
if exists("did_load_filetypes") if exists("did_load_filetypes")
@@ -193,7 +193,8 @@ au BufNewFile,BufRead *.awk,*.gawk setf awk
au BufNewFile,BufRead *.mch,*.ref,*.imp setf b au BufNewFile,BufRead *.mch,*.ref,*.imp setf b
" BASIC or Visual Basic " BASIC or Visual Basic
au BufNewFile,BufRead *.bas call polyglot#ft#FTVB("basic") au BufNewFile,BufRead *.bas call polyglot#ft#FTbas()
au BufNewFile,BufRead *.bi,*.bm call polyglot#ft#FTbas()
" Visual Basic Script (close to Visual Basic) or Visual Basic .NET " Visual Basic Script (close to Visual Basic) or Visual Basic .NET
au BufNewFile,BufRead *.vb,*.vbs,*.dsm,*.ctl setf vb au BufNewFile,BufRead *.vb,*.vbs,*.dsm,*.ctl setf vb
@@ -202,7 +203,7 @@ au BufNewFile,BufRead *.vb,*.vbs,*.dsm,*.ctl setf vb
au BufNewFile,BufRead *.iba,*.ibi setf ibasic au BufNewFile,BufRead *.iba,*.ibi setf ibasic
" FreeBasic file (similar to QBasic) " FreeBasic file (similar to QBasic)
au BufNewFile,BufRead *.fb,*.bi setf freebasic au BufNewFile,BufRead *.fb setf freebasic
" Batch file for MSDOS. " Batch file for MSDOS.
au BufNewFile,BufRead *.bat,*.sys setf dosbatch au BufNewFile,BufRead *.bat,*.sys setf dosbatch
@@ -497,7 +498,7 @@ au BufNewFile,BufRead */debian/patches/* call polyglot#ft#Dep3patch()
" Diff files " Diff files
au BufNewFile,BufRead *.diff,*.rej setf diff au BufNewFile,BufRead *.diff,*.rej setf diff
au BufNewFile,BufRead *.patch au BufNewFile,BufRead *.patch
\ if getline(1) =~ '^From [0-9a-f]\{40\} Mon Sep 17 00:00:00 2001$' | \ if getline(1) =~# '^From [0-9a-f]\{40,\} Mon Sep 17 00:00:00 2001$' |
\ setf gitsendemail | \ setf gitsendemail |
\ else | \ else |
\ setf diff | \ setf diff |
@@ -653,6 +654,9 @@ au BufNewFile,BufRead *.fsl setf framescript
" FStab " FStab
au BufNewFile,BufRead fstab,mtab setf fstab au BufNewFile,BufRead fstab,mtab setf fstab
" Fusion
au BufRead,BufNewFile *.fusion setf fusion
" F# or Forth " F# or Forth
au BufNewFile,BufRead *.fs call polyglot#ft#FTfs() au BufNewFile,BufRead *.fs call polyglot#ft#FTfs()
@@ -665,6 +669,12 @@ au BufNewFile,BufRead .gdbinit,gdbinit setf gdb
" GDMO " GDMO
au BufNewFile,BufRead *.mo,*.gdmo setf gdmo au BufNewFile,BufRead *.mo,*.gdmo setf gdmo
" GDscript
au BufNewFile,BufRead *.gd setf gdscript
" Godot resource
au BufRead,BufNewFile *.tscn,*.tres setf gdresource
" Gedcom " Gedcom
au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom au BufNewFile,BufRead *.ged,lltxxxxx.txt setf gedcom
@@ -676,26 +686,28 @@ autocmd BufRead,BufNewFile *.gift setf gift
" Git " Git
au BufNewFile,BufRead COMMIT_EDITMSG,MERGE_MSG,TAG_EDITMSG setf gitcommit au BufNewFile,BufRead COMMIT_EDITMSG,MERGE_MSG,TAG_EDITMSG setf gitcommit
au BufNewFile,BufRead *.git/config,.gitconfig,/etc/gitconfig setf gitconfig au BufNewFile,BufRead NOTES_EDITMSG,EDIT_DESCRIPTION setf gitcommit
au BufNewFile,BufRead *.git/config,.gitconfig,*/etc/gitconfig setf gitconfig
au BufNewFile,BufRead */.config/git/config setf gitconfig au BufNewFile,BufRead */.config/git/config setf gitconfig
au BufNewFile,BufRead *.git/config.worktree setf gitconfig
au BufNewFile,BufRead *.git/worktrees/*/config.worktree setf gitconfig
au BufNewFile,BufRead .gitmodules,*.git/modules/*/config setf gitconfig au BufNewFile,BufRead .gitmodules,*.git/modules/*/config setf gitconfig
if !empty($XDG_CONFIG_HOME) if !empty($XDG_CONFIG_HOME)
au BufNewFile,BufRead $XDG_CONFIG_HOME/git/config setf gitconfig au BufNewFile,BufRead $XDG_CONFIG_HOME/git/config setf gitconfig
endif endif
au BufNewFile,BufRead git-rebase-todo setf gitrebase au BufNewFile,BufRead git-rebase-todo setf gitrebase
au BufRead,BufNewFile .gitsendemail.msg.?????? setf gitsendemail au BufRead,BufNewFile .gitsendemail.msg.?????? setf gitsendemail
au BufNewFile,BufRead .msg.[0-9]*
\ if getline(1) =~ '^From.*# This line is ignored.$' |
\ setf gitsendemail |
\ endif
au BufNewFile,BufRead *.git/* au BufNewFile,BufRead *.git/*
\ if getline(1) =~ '^\x\{40\}\>\|^ref: ' | \ if getline(1) =~# '^\x\{40,\}\>\|^ref: ' |
\ setf git | \ setf git |
\ endif \ endif
" Gkrellmrc " Gkrellmrc
au BufNewFile,BufRead gkrellmrc,gkrellmrc_? setf gkrellmrc au BufNewFile,BufRead gkrellmrc,gkrellmrc_? setf gkrellmrc
" GLSL
au BufNewFile,BufRead *.glsl setf glsl
" GP scripts (2.0 and onward) " GP scripts (2.0 and onward)
au BufNewFile,BufRead *.gp,.gprc setf gp au BufNewFile,BufRead *.gp,.gprc setf gp
@@ -716,15 +728,19 @@ au BufNewFile,BufRead gitolite.conf setf gitolite
au BufNewFile,BufRead {,.}gitolite.rc,example.gitolite.rc setf perl au BufNewFile,BufRead {,.}gitolite.rc,example.gitolite.rc setf perl
" Gnuplot scripts " Gnuplot scripts
au BufNewFile,BufRead *.gpi setf gnuplot au BufNewFile,BufRead *.gpi,.gnuplot setf gnuplot
" Go (Google) " Go (Google)
au BufNewFile,BufRead *.go setf go au BufNewFile,BufRead *.go setf go
au BufNewFile,BufRead Gopkg.lock setf toml au BufNewFile,BufRead Gopkg.lock setf toml
au BufRead,BufNewFile go.work setf gowork
" GrADS scripts " GrADS scripts
au BufNewFile,BufRead *.gs setf grads au BufNewFile,BufRead *.gs setf grads
" GraphQL
au BufNewFile,BufRead *.graphql,*.graphqls,*.gql setf graphql
" Gretl " Gretl
au BufNewFile,BufRead *.gretl setf gretl au BufNewFile,BufRead *.gretl setf gretl
@@ -740,12 +756,18 @@ au BufNewFile,BufRead */etc/group,*/etc/group-,*/etc/group.edit,*/etc/gshadow,*/
" GTK RC " GTK RC
au BufNewFile,BufRead .gtkrc,gtkrc setf gtkrc au BufNewFile,BufRead .gtkrc,gtkrc setf gtkrc
" Hack
au BufRead,BufNewFile *.hack,*.hackpartial setf hack
" Haml " Haml
au BufNewFile,BufRead *.haml setf haml au BufNewFile,BufRead *.haml setf haml
" Hamster Classic | Playground files " Hamster Classic | Playground files
au BufNewFile,BufRead *.hsm setf hamster au BufNewFile,BufRead *.hsm setf hamster
" Handlebars
au BufNewFile,BufRead *.hbs setf handlebars
" Haskell " Haskell
au BufNewFile,BufRead *.hs,*.hsc,*.hs-boot,*.hsig setf haskell au BufNewFile,BufRead *.hs,*.hsc,*.hs-boot,*.hsig setf haskell
au BufNewFile,BufRead *.lhs setf lhaskell au BufNewFile,BufRead *.lhs setf lhaskell
@@ -758,12 +780,21 @@ au BufNewFile,BufRead cabal.config setf cabalconfig
au BufNewFile,BufRead *.ht setf haste au BufNewFile,BufRead *.ht setf haste
au BufNewFile,BufRead *.htpp setf hastepreproc au BufNewFile,BufRead *.htpp setf hastepreproc
" HCL
au BufRead,BufNewFile *.hcl setf hcl
" Hercules " Hercules
au BufNewFile,BufRead *.vc,*.ev,*.sum,*.errsum setf hercules au BufNewFile,BufRead *.vc,*.ev,*.sum,*.errsum setf hercules
" HEEx
au BufRead,BufNewFile *.heex setf heex
" HEX (Intel) " HEX (Intel)
au BufNewFile,BufRead *.hex,*.h32 setf hex au BufNewFile,BufRead *.hex,*.h32 setf hex
" Hjson
au BufNewFile,BufRead *.hjson setf hjson
" Hollywood " Hollywood
au BufRead,BufNewFile *.hws setf hollywood au BufRead,BufNewFile *.hws setf hollywood
@@ -888,6 +919,9 @@ au BufNewFile,BufRead *.jov,*.j73,*.jovial setf jovial
" JSON " JSON
au BufNewFile,BufRead *.json,*.jsonp,*.webmanifest setf json au BufNewFile,BufRead *.json,*.jsonp,*.webmanifest setf json
" JSON5
au BufNewFile,BufRead *.json5 setf json5
" JSON Patch (RFC 6902) " JSON Patch (RFC 6902)
au BufNewFile,BufRead *.json-patch setf json au BufNewFile,BufRead *.json-patch setf json
@@ -939,6 +973,9 @@ au BufNewFile,BufRead *.ldif setf ldif
" Ld loader " Ld loader
au BufNewFile,BufRead *.ld setf ld au BufNewFile,BufRead *.ld setf ld
" Ledger
au BufRead,BufNewFile *.ldg,*.ledger,*.journal setf ledger
" Less " Less
au BufNewFile,BufRead *.less setf less au BufNewFile,BufRead *.less setf less
@@ -1176,6 +1213,9 @@ au BufNewFile,BufRead *.nginx,nginx*.conf,*nginx.conf,*/etc/nginx/*,*/usr/local/
" Ninja file " Ninja file
au BufNewFile,BufRead *.ninja setf ninja au BufNewFile,BufRead *.ninja setf ninja
" Nix
au BufRead,BufNewFile *.nix setf nix
" NPM RC file " NPM RC file
au BufNewFile,BufRead npmrc,.npmrc setf dosini au BufNewFile,BufRead npmrc,.npmrc setf dosini
@@ -1217,6 +1257,9 @@ au BufNewFile,BufRead *.xom,*.xin setf omnimark
" OPAM " OPAM
au BufNewFile,BufRead opam,*.opam,*.opam.template setf opam au BufNewFile,BufRead opam,*.opam,*.opam.template setf opam
" OpenFOAM
au BufNewFile,BufRead [a-zA-Z0-9]*Dict\(.*\)\=,[a-zA-Z]*Properties\(.*\)\=,*Transport\(.*\),fvSchemes,fvSolution,fvConstrains,fvModels,*/constant/g,*/0\(\.orig\)\=/* call polyglot#ft#FTfoam()
" OpenROAD " OpenROAD
au BufNewFile,BufRead *.or setf openroad au BufNewFile,BufRead *.or setf openroad
@@ -1358,6 +1401,9 @@ au BufNewFile,BufRead *printcap
au BufNewFile,BufRead *termcap au BufNewFile,BufRead *termcap
\ let b:ptcap_type = "term" | setf ptcap \ let b:ptcap_type = "term" | setf ptcap
" Prisma
au BufRead,BufNewFile *.prisma setf prisma
" PCCTS / ANTLR " PCCTS / ANTLR
"au BufNewFile,BufRead *.g setf antlr "au BufNewFile,BufRead *.g setf antlr
au BufNewFile,BufRead *.g setf pccts au BufNewFile,BufRead *.g setf pccts
@@ -1365,6 +1411,9 @@ au BufNewFile,BufRead *.g setf pccts
" PPWizard " PPWizard
au BufNewFile,BufRead *.it,*.ih setf ppwiz au BufNewFile,BufRead *.it,*.ih setf ppwiz
" Pug
au BufRead,BufNewFile *.pug setf pug
" Puppet " Puppet
au BufNewFile,BufRead Puppetfile setf ruby au BufNewFile,BufRead Puppetfile setf ruby
@@ -1430,6 +1479,9 @@ au BufNewFile,BufRead *.pyx,*.pxd setf pyrex
au BufNewFile,BufRead *.py,*.pyw,.pythonstartup,.pythonrc setf python au BufNewFile,BufRead *.py,*.pyw,.pythonstartup,.pythonrc setf python
au BufNewFile,BufRead *.ptl,*.pyi,SConstruct setf python au BufNewFile,BufRead *.ptl,*.pyi,SConstruct setf python
" QL
au BufRead,BufNewFile *.ql,*.qll setf ql
" Radiance " Radiance
au BufNewFile,BufRead *.rad,*.mat setf radiance au BufNewFile,BufRead *.rad,*.mat setf radiance
@@ -1495,6 +1547,9 @@ au BufNewFile,BufRead *.r,*.R call polyglot#ft#FTr()
" Remind " Remind
au BufNewFile,BufRead .reminders,*.remind,*.rem setf remind au BufNewFile,BufRead .reminders,*.remind,*.rem setf remind
" ReScript
au BufNewFile,BufRead *.res,*.resi setf rescript
" Resolv.conf " Resolv.conf
au BufNewFile,BufRead resolv.conf setf resolv au BufNewFile,BufRead resolv.conf setf resolv
@@ -1778,7 +1833,7 @@ au BufNewFile,BufRead *.sqr,*.sqi setf sqr
au BufNewFile,BufRead *.nut setf squirrel au BufNewFile,BufRead *.nut setf squirrel
" OpenSSH configuration " OpenSSH configuration
au BufNewFile,BufRead ssh_config,*/.ssh/config setf sshconfig au BufNewFile,BufRead ssh_config,*/.ssh/config,*/.ssh/*.conf setf sshconfig
au BufNewFile,BufRead */etc/ssh/ssh_config.d/*.conf setf sshconfig au BufNewFile,BufRead */etc/ssh/ssh_config.d/*.conf setf sshconfig
" OpenSSH server configuration " OpenSSH server configuration
@@ -1834,6 +1889,9 @@ au BufNewFile,BufRead */etc/sudoers,sudoers.tmp setf sudoers
" SVG (Scalable Vector Graphics) " SVG (Scalable Vector Graphics)
au BufNewFile,BufRead *.svg setf svg au BufNewFile,BufRead *.svg setf svg
" Surface
au BufRead,BufNewFile *.sface setf surface
" Tads (or Nroff or Perl test file) " Tads (or Nroff or Perl test file)
au BufNewFile,BufRead *.t au BufNewFile,BufRead *.t
\ if !polyglot#ft#FTnroff() && !polyglot#ft#FTperl() | setf tads | endif \ if !polyglot#ft#FTnroff() && !polyglot#ft#FTperl() | setf tads | endif
@@ -1851,6 +1909,9 @@ au BufRead,BufNewFile *.task setf taskedit
" Tcl (JACL too) " Tcl (JACL too)
au BufNewFile,BufRead *.tcl,*.tm,*.tk,*.itcl,*.itk,*.jacl,.tclshrc,.wishrc setf tcl au BufNewFile,BufRead *.tcl,*.tm,*.tk,*.itcl,*.itk,*.jacl,.tclshrc,.wishrc setf tcl
" Teal
au BufRead,BufNewFile *.tl setf teal
" TealInfo " TealInfo
au BufNewFile,BufRead *.tli setf tli au BufNewFile,BufRead *.tli setf tli
@@ -1868,6 +1929,9 @@ au BufRead,BufNewFile *.ttl
" Terminfo " Terminfo
au BufNewFile,BufRead *.ti setf terminfo au BufNewFile,BufRead *.ti setf terminfo
" Terraform
au BufRead,BufNewFile *.tfvars setf terraform
" TeX " TeX
au BufNewFile,BufRead *.latex,*.sty,*.dtx,*.ltx,*.bbl setf tex au BufNewFile,BufRead *.latex,*.sty,*.dtx,*.ltx,*.bbl setf tex
au BufNewFile,BufRead *.tex call polyglot#ft#FTtex() au BufNewFile,BufRead *.tex call polyglot#ft#FTtex()
@@ -1885,7 +1949,13 @@ au BufNewFile,BufRead texmf.cnf setf texmf
au BufNewFile,BufRead .tidyrc,tidyrc,tidy.conf setf tidy au BufNewFile,BufRead .tidyrc,tidyrc,tidy.conf setf tidy
" TF mud client " TF mud client
au BufNewFile,BufRead *.tf,.tfrc,tfrc setf tf au BufNewFile,BufRead .tfrc,tfrc setf tf
" TF mud client or terraform
au BufNewFile,BufRead *.tf call polyglot#ft#FTtf()
" TLA+
au BufNewFile,BufRead *.tla setf tla
" tmux configuration " tmux configuration
au BufNewFile,BufRead {.,}tmux*.conf setf tmux au BufNewFile,BufRead {.,}tmux*.conf setf tmux
@@ -1894,7 +1964,7 @@ au BufNewFile,BufRead {.,}tmux*.conf setf tmux
au BufNewFile,BufRead *.toml setf toml au BufNewFile,BufRead *.toml setf toml
" TPP - Text Presentation Program " TPP - Text Presentation Program
au BufNewFile,BufReadPost *.tpp setf tpp au BufNewFile,BufRead *.tpp setf tpp
" Treetop " Treetop
au BufRead,BufNewFile *.treetop setf treetop au BufRead,BufNewFile *.treetop setf treetop
@@ -1951,6 +2021,9 @@ au BufNewFile,BufRead */.init/*.conf,*/.init/*.override setf upstart
au BufNewFile,BufRead */.config/upstart/*.conf setf upstart au BufNewFile,BufRead */.config/upstart/*.conf setf upstart
au BufNewFile,BufRead */.config/upstart/*.override setf upstart au BufNewFile,BufRead */.config/upstart/*.override setf upstart
" Vala
au BufNewFile,BufRead *.vala setf vala
" Vera " Vera
au BufNewFile,BufRead *.vr,*.vri,*.vrh setf vera au BufNewFile,BufRead *.vr,*.vri,*.vrh setf vera
@@ -1981,7 +2054,7 @@ au BufRead,BufNewFile *.hw,*.module,*.pkg
\ endif \ endif
" Visual Basic (also uses *.bas) or FORM " Visual Basic (also uses *.bas) or FORM
au BufNewFile,BufRead *.frm call polyglot#ft#FTVB("form") au BufNewFile,BufRead *.frm call polyglot#ft#FTfrm()
" SaxBasic is close to Visual Basic " SaxBasic is close to Visual Basic
au BufNewFile,BufRead *.sba setf vb au BufNewFile,BufRead *.sba setf vb
@@ -2145,6 +2218,9 @@ au BufNewFile,BufRead *.raml setf raml
" yum conf (close enough to dosini) " yum conf (close enough to dosini)
au BufNewFile,BufRead */etc/yum.conf setf dosini au BufNewFile,BufRead */etc/yum.conf setf dosini
" YANG
au BufRead,BufNewFile *.yang setf yang
" Zimbu " Zimbu
au BufNewFile,BufRead *.zu setf zimbu au BufNewFile,BufRead *.zu setf zimbu
" Zimbu Templates " Zimbu Templates
@@ -2284,6 +2360,9 @@ au BufNewFile,BufRead Kconfig.* call s:StarSetf('kconfig')
" Lilo: Linux loader " Lilo: Linux loader
au BufNewFile,BufRead lilo.conf* call s:StarSetf('lilo') au BufNewFile,BufRead lilo.conf* call s:StarSetf('lilo')
" Libsensors
au BufNewFile,BufRead */etc/sensors.d/[^.]* call s:StarSetf('sensors')
" Logcheck " Logcheck
au BufNewFile,BufRead */etc/logcheck/*.d*/* call s:StarSetf('logcheck') au BufNewFile,BufRead */etc/logcheck/*.d*/* call s:StarSetf('logcheck')

File diff suppressed because it is too large Load Diff

View File

@@ -3,9 +3,9 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'basic', 'ftplugin/basic.vim')
endif endif
" Vim filetype plugin file " Vim filetype plugin file
" Language: BASIC " Language: BASIC (QuickBASIC 4.5)
" Maintainer: Doug Kearns <dougkearns@gmail.com> " Maintainer: Doug Kearns <dougkearns@gmail.com>
" Last Change: 2015 Jan 10 " Last Change: 2021 Mar 16
if exists("b:did_ftplugin") if exists("b:did_ftplugin")
finish finish
@@ -15,17 +15,46 @@ let b:did_ftplugin = 1
let s:cpo_save = &cpo let s:cpo_save = &cpo
set cpo&vim set cpo&vim
setlocal comments=:REM,:' setlocal comments=:REM\ ,:Rem\ ,:rem\ ,:'
setlocal commentstring='\ %s setlocal commentstring='\ %s
setlocal formatoptions-=t formatoptions+=croql setlocal formatoptions-=t formatoptions+=croql
" TODO: support exit ... as middle matches?
if exists("loaded_matchit") && !exists("b:match_words")
let s:line_start = '\%(^\s*\)\@<='
let s:not_end = '\%(end\s\+\)\@<!'
let s:not_end_or_exit = '\%(\%(end\|exit\)\s\+\)\@<!'
let b:match_ignorecase = 1
let b:match_words =
\ s:not_end_or_exit .. '\<def\s\+fn:\<end\s\+def\>,' ..
\ s:not_end_or_exit .. '\<function\>:\<end\s\+function\>,' ..
\ s:not_end_or_exit .. '\<sub\>:\<end\s\+sub\>,' ..
\ s:not_end .. '\<type\>:\<end\s\+type\>,' ..
\ s:not_end .. '\<select\>:\%(select\s\+\)\@<!\<case\%(\s\+\%(else\|is\)\)\=\>:\<end\s\+select\>,' ..
\ '\<do\>:\<loop\>,' ..
\ '\<for\>\%(\s\+\%(input\|output\|random\|append\|binary\)\)\@!:\<next\>,' ..
\ '\<while\>:\<wend\>,' ..
\ s:line_start .. 'if\%(.*\<then\s*\%($\|''\)\)\@=:\<\%(' .. s:line_start .. 'else\|elseif\)\>:\<end\s\+if\>,' ..
\ '\<lock\>:\<unlock\>'
let b:match_skip = 'synIDattr(synID(line("."),col("."),1),"name") =~? "comment\\|string" || ' ..
\ 'strpart(getline("."), 0, col(".") ) =~? "\\<exit\\s\\+"'
unlet s:line_start s:not_end s:not_end_or_exit
endif
if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter") if (has("gui_win32") || has("gui_gtk")) && !exists("b:browsefilter")
let b:browsefilter = "BASIC Source Files (*.bas)\t*.bas\n" . let b:browsefilter = "BASIC Source Files (*.bas)\t*.bas\n" ..
\ "BASIC Include Files (*.bi, *.bm)\t*.bi;*.bm\n" ..
\ "All Files (*.*)\t*.*\n" \ "All Files (*.*)\t*.*\n"
endif endif
let b:undo_ftplugin = "setl fo< com< cms< sua<" . let b:undo_ftplugin = "setl fo< com< cms<" ..
\ " | unlet! b:match_ignorecase b:match_skip b:match_words" ..
\ " | unlet! b:browsefilter" \ " | unlet! b:browsefilter"
let &cpo = s:cpo_save let &cpo = s:cpo_save
unlet s:cpo_save unlet s:cpo_save
" vim: nowrap sw=2 sts=2 ts=8 noet fdm=marker:

View File

@@ -3,15 +3,67 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'freebasic', 'ftplugin/freebas
endif endif
" Vim filetype plugin file " Vim filetype plugin file
" Language: FreeBasic " Language: FreeBASIC
" Maintainer: Doug Kearns <dougkearns@gmail.com> " Maintainer: Doug Kearns <dougkearns@gmail.com>
" Last Change: 2015 Jan 10 " Last Change: 2021 Mar 16
" Setup {{{1
if exists("b:did_ftplugin") if exists("b:did_ftplugin")
finish finish
endif endif
let b:did_ftplugin = 1
let s:cpo_save = &cpo
set cpo&vim
runtime! ftplugin/basic.vim runtime! ftplugin/basic.vim
" vim: ts=8 let s:dialect = freebasic#GetDialect()
" Comments {{{1
" add ''comments before 'comments
let &l:comments = "sO:*\ -,mO:*\ \ ,exO:*/,s1:/',mb:',ex:'/,:''," .. &l:comments
" Match words {{{1
if exists("loaded_matchit")
let s:not_end = '\%(end\s\+\)\@<!'
let b:match_words .= ','
if s:dialect == 'fb'
let b:match_words .= s:not_end .. '\<constructor\>:\<end\s\+constructor\>,' ..
\ s:not_end .. '\<destructor\>:\<end\s\+destructor\>,' ..
\ s:not_end .. '\<property\>:\<end\s\+property\>,' ..
\ s:not_end .. '\<operator\>:\<end\s\+operator\>,' ..
\ s:not_end .. '\<extern\%(\s\+"\)\@=:\<end\s\+extern\>,'
endif
if s:dialect == 'fb' || s:dialect == 'deprecated'
let b:match_words .= s:not_end .. '\<scope\>:\<end\s\+scope\>,'
endif
if s:dialect == 'qb'
let b:match_words .= s:not_end .. '\<__asm\>:\<end\s\+__asm\>,' ..
\ s:not_end .. '\<__union\>:\<end\s\+__union\>,' ..
\ s:not_end .. '\<__with\>:\<end\s\+__with\>,'
else
let b:match_words .= s:not_end .. '\<asm\>:\<end\s\+asm\>,' ..
\ s:not_end .. '\<namespace\>:\<end\s\+namespace\>,' ..
\ s:not_end .. '\<union\>:\<end\s\+union\>,' ..
\ s:not_end .. '\<with\>:\<end\s\+with\>,'
endif
let b:match_words .= s:not_end .. '\<enum\>:\<end\s\+enum\>,' ..
\ '^#\s*\%(if\|ifdef\|ifndef\)\>:^#\s*\%(else\|elseif\)\>:^#\s*endif\>,' ..
\ '^#\s*macro\>:^#\s*endmacro\>'
" skip "function = <retval>"
let b:match_skip .= '|| strpart(getline("."), col(".") - 1) =~? "^\\<function\\s\\+="'
unlet s:not_end
endif
" Cleanup {{{1
let &cpo = s:cpo_save
unlet s:cpo_save
" vim: nowrap sw=2 sts=2 ts=8 noet fdm=marker:

View File

@@ -98,7 +98,7 @@ endfunction
" "
function! s:MoveToCurHeader() function! s:MoveToCurHeader()
let l:lineNum = s:GetHeaderLineNum() let l:lineNum = s:GetHeaderLineNum()
if l:lineNum != 0 if l:lineNum !=# 0
call cursor(l:lineNum, 1) call cursor(l:lineNum, 1)
else else
echo 'outside any header' echo 'outside any header'
@@ -151,7 +151,7 @@ function! s:GetHeaderLevel(...)
let l:line = a:1 let l:line = a:1
endif endif
let l:linenum = s:GetHeaderLineNum(l:line) let l:linenum = s:GetHeaderLineNum(l:line)
if l:linenum != 0 if l:linenum !=# 0
return s:GetLevelOfHeaderAtLine(l:linenum) return s:GetLevelOfHeaderAtLine(l:linenum)
else else
return 0 return 0
@@ -165,13 +165,13 @@ function! s:GetHeaderList()
let l:fenced_block = 0 let l:fenced_block = 0
let l:front_matter = 0 let l:front_matter = 0
let l:header_list = [] let l:header_list = []
let l:vim_markdown_frontmatter = get(g:, "vim_markdown_frontmatter", 0) let l:vim_markdown_frontmatter = get(g:, 'vim_markdown_frontmatter', 0)
for i in range(1, line('$')) for i in range(1, line('$'))
let l:lineraw = getline(i) let l:lineraw = getline(i)
let l:l1 = getline(i+1) let l:l1 = getline(i+1)
let l:line = substitute(l:lineraw, "#", "\\\#", "g") let l:line = substitute(l:lineraw, '#', "\\\#", 'g')
" exclude lines in fenced code blocks " exclude lines in fenced code blocks
if l:line =~ '````*' || l:line =~ '\~\~\~\~*' if l:line =~# '````*' || l:line =~# '\~\~\~\~*'
if l:fenced_block == 0 if l:fenced_block == 0
let l:fenced_block = 1 let l:fenced_block = 1
elseif l:fenced_block == 1 elseif l:fenced_block == 1
@@ -180,24 +180,24 @@ function! s:GetHeaderList()
" exclude lines in frontmatters " exclude lines in frontmatters
elseif l:vim_markdown_frontmatter == 1 elseif l:vim_markdown_frontmatter == 1
if l:front_matter == 1 if l:front_matter == 1
if l:line == '---' if l:line ==# '---'
let l:front_matter = 0 let l:front_matter = 0
endif endif
elseif i == 1 elseif i == 1
if l:line == '---' if l:line ==# '---'
let l:front_matter = 1 let l:front_matter = 1
endif endif
endif endif
endif endif
" match line against header regex " match line against header regex
if join(getline(i, i + 1), "\n") =~ s:headersRegexp && l:line =~ '^\S' if join(getline(i, i + 1), "\n") =~# s:headersRegexp && l:line =~# '^\S'
let l:is_header = 1 let l:is_header = 1
else else
let l:is_header = 0 let l:is_header = 0
endif endif
if l:is_header == 1 && l:fenced_block == 0 && l:front_matter == 0 if l:is_header ==# 1 && l:fenced_block ==# 0 && l:front_matter ==# 0
" remove hashes from atx headers " remove hashes from atx headers
if match(l:line, "^#") > -1 if match(l:line, '^#') > -1
let l:line = substitute(l:line, '\v^#*[ ]*', '', '') let l:line = substitute(l:line, '\v^#*[ ]*', '', '')
let l:line = substitute(l:line, '\v[ ]*#*$', '', '') let l:line = substitute(l:line, '\v[ ]*#*$', '', '')
endif endif
@@ -365,11 +365,11 @@ function! s:Toc(...)
let l:header_list = s:GetHeaderList() let l:header_list = s:GetHeaderList()
let l:indented_header_list = [] let l:indented_header_list = []
if len(l:header_list) == 0 if len(l:header_list) == 0
echom "Toc: No headers." echom 'Toc: No headers.'
return return
endif endif
let l:header_max_len = 0 let l:header_max_len = 0
let l:vim_markdown_toc_autofit = get(g:, "vim_markdown_toc_autofit", 0) let l:vim_markdown_toc_autofit = get(g:, 'vim_markdown_toc_autofit', 0)
for h in l:header_list for h in l:header_list
" set header number of the cursor position " set header number of the cursor position
if l:cursor_header == 0 if l:cursor_header == 0
@@ -442,7 +442,7 @@ function! s:InsertToc(format, ...)
let l:toc = [] let l:toc = []
let l:header_list = s:GetHeaderList() let l:header_list = s:GetHeaderList()
if len(l:header_list) == 0 if len(l:header_list) == 0
echom "InsertToc: No headers." echom 'InsertToc: No headers.'
return return
endif endif
@@ -554,7 +554,7 @@ function! s:TableFormat()
" Move colons for alignment to left or right side of the cell. " Move colons for alignment to left or right side of the cell.
execute 's/:\( \+\)|/\1:|/e' . l:flags execute 's/:\( \+\)|/\1:|/e' . l:flags
execute 's/|\( \+\):/|:\1/e' . l:flags execute 's/|\( \+\):/|:\1/e' . l:flags
execute 's/ /-/' . l:flags execute 's/|:\?\zs[ -]\+\ze:\?|/\=repeat("-", len(submatch(0)))/' . l:flags
call setpos('.', l:pos) call setpos('.', l:pos)
endfunction endfunction
@@ -657,7 +657,7 @@ endfunction
" "
function! s:OpenUrlUnderCursor() function! s:OpenUrlUnderCursor()
let l:url = s:Markdown_GetUrlForPosition(line('.'), col('.')) let l:url = s:Markdown_GetUrlForPosition(line('.'), col('.'))
if l:url != '' if l:url !=# ''
call s:VersionAwareNetrwBrowseX(l:url) call s:VersionAwareNetrwBrowseX(l:url)
else else
echomsg 'The cursor is not on a link.' echomsg 'The cursor is not on a link.'
@@ -668,8 +668,24 @@ endfunction
" script while this function is running. We must not replace it. " script while this function is running. We must not replace it.
if !exists('*s:EditUrlUnderCursor') if !exists('*s:EditUrlUnderCursor')
function s:EditUrlUnderCursor() function s:EditUrlUnderCursor()
let l:editmethod = ''
" determine how to open the linked file (split, tab, etc)
if exists('g:vim_markdown_edit_url_in')
if g:vim_markdown_edit_url_in ==# 'tab'
let l:editmethod = 'tabnew'
elseif g:vim_markdown_edit_url_in ==# 'vsplit'
let l:editmethod = 'vsp'
elseif g:vim_markdown_edit_url_in ==# 'hsplit'
let l:editmethod = 'sp'
else
let l:editmethod = 'edit'
endif
else
" default to current buffer
let l:editmethod = 'edit'
endif
let l:url = s:Markdown_GetUrlForPosition(line('.'), col('.')) let l:url = s:Markdown_GetUrlForPosition(line('.'), col('.'))
if l:url != '' if l:url !=# ''
if get(g:, 'vim_markdown_autowrite', 0) if get(g:, 'vim_markdown_autowrite', 0)
write write
endif endif
@@ -679,14 +695,14 @@ if !exists('*s:EditUrlUnderCursor')
if len(l:parts) == 2 if len(l:parts) == 2
let [l:url, l:anchor] = parts let [l:url, l:anchor] = parts
let l:anchorexpr = get(g:, 'vim_markdown_anchorexpr', '') let l:anchorexpr = get(g:, 'vim_markdown_anchorexpr', '')
if l:anchorexpr != '' if l:anchorexpr !=# ''
let l:anchor = eval(substitute( let l:anchor = eval(substitute(
\ l:anchorexpr, 'v:anchor', \ l:anchorexpr, 'v:anchor',
\ escape('"'.l:anchor.'"', '"'), '')) \ escape('"'.l:anchor.'"', '"'), ''))
endif endif
endif endif
endif endif
if l:url != '' if l:url !=# ''
let l:ext = '' let l:ext = ''
if get(g:, 'vim_markdown_no_extensions_in_markdown', 0) if get(g:, 'vim_markdown_no_extensions_in_markdown', 0)
" use another file extension if preferred " use another file extension if preferred
@@ -697,29 +713,13 @@ if !exists('*s:EditUrlUnderCursor')
endif endif
endif endif
let l:url = fnameescape(fnamemodify(expand('%:h').'/'.l:url.l:ext, ':.')) let l:url = fnameescape(fnamemodify(expand('%:h').'/'.l:url.l:ext, ':.'))
let l:editmethod = ''
" determine how to open the linked file (split, tab, etc)
if exists('g:vim_markdown_edit_url_in')
if g:vim_markdown_edit_url_in == 'tab'
let l:editmethod = 'tabnew'
elseif g:vim_markdown_edit_url_in == 'vsplit'
let l:editmethod = 'vsp'
elseif g:vim_markdown_edit_url_in == 'hsplit'
let l:editmethod = 'sp'
else
let l:editmethod = 'edit'
endif
else
" default to current buffer
let l:editmethod = 'edit'
endif
execute l:editmethod l:url execute l:editmethod l:url
endif endif
if l:anchor != '' if l:anchor !=# ''
silent! execute '/'.l:anchor silent! execute '/'.l:anchor
endif endif
else else
echomsg 'The cursor is not on a link.' execute l:editmethod . ' <cfile>'
endif endif
endfunction endfunction
endif endif
@@ -754,7 +754,7 @@ if !get(g:, 'vim_markdown_no_default_key_mappings', 0)
call <sid>MapNotHasmapto('][', 'Markdown_MoveToNextSiblingHeader') call <sid>MapNotHasmapto('][', 'Markdown_MoveToNextSiblingHeader')
call <sid>MapNotHasmapto('[]', 'Markdown_MoveToPreviousSiblingHeader') call <sid>MapNotHasmapto('[]', 'Markdown_MoveToPreviousSiblingHeader')
call <sid>MapNotHasmapto(']u', 'Markdown_MoveToParentHeader') call <sid>MapNotHasmapto(']u', 'Markdown_MoveToParentHeader')
call <sid>MapNotHasmapto(']c', 'Markdown_MoveToCurHeader') call <sid>MapNotHasmapto(']h', 'Markdown_MoveToCurHeader')
call <sid>MapNotHasmapto('gx', 'Markdown_OpenUrlUnderCursor') call <sid>MapNotHasmapto('gx', 'Markdown_OpenUrlUnderCursor')
call <sid>MapNotHasmapto('ge', 'Markdown_EditUrlUnderCursor') call <sid>MapNotHasmapto('ge', 'Markdown_EditUrlUnderCursor')
endif endif
@@ -774,8 +774,8 @@ command! -buffer -nargs=? InsertNToc call s:InsertToc('numbers', <args>)
if exists('g:vim_markdown_fenced_languages') if exists('g:vim_markdown_fenced_languages')
let s:filetype_dict = {} let s:filetype_dict = {}
for s:filetype in g:vim_markdown_fenced_languages for s:filetype in g:vim_markdown_fenced_languages
let key = matchstr(s:filetype, "[^=]*") let key = matchstr(s:filetype, '[^=]*')
let val = matchstr(s:filetype, "[^=]*$") let val = matchstr(s:filetype, '[^=]*$')
let s:filetype_dict[key] = val let s:filetype_dict[key] = val
endfor endfor
else else
@@ -793,7 +793,7 @@ function! s:MarkdownHighlightSources(force)
let filetypes = {} let filetypes = {}
for line in getline(1, '$') for line in getline(1, '$')
let ft = matchstr(line, '```\s*\zs[0-9A-Za-z_+-]*\ze.*') let ft = matchstr(line, '```\s*\zs[0-9A-Za-z_+-]*\ze.*')
if !empty(ft) && ft !~ '^\d*$' | let filetypes[ft] = 1 | endif if !empty(ft) && ft !~# '^\d*$' | let filetypes[ft] = 1 | endif
endfor endfor
if !exists('b:mkd_known_filetypes') if !exists('b:mkd_known_filetypes')
let b:mkd_known_filetypes = {} let b:mkd_known_filetypes = {}
@@ -816,7 +816,7 @@ function! s:MarkdownHighlightSources(force)
else else
let filetype = ft let filetype = ft
endif endif
let group = 'mkdSnippet' . toupper(substitute(filetype, "[+-]", "_", "g")) let group = 'mkdSnippet' . toupper(substitute(filetype, '[+-]', '_', 'g'))
if !has_key(b:mkd_included_filetypes, filetype) if !has_key(b:mkd_included_filetypes, filetype)
let include = s:SyntaxInclude(filetype) let include = s:SyntaxInclude(filetype)
let b:mkd_included_filetypes[filetype] = 1 let b:mkd_included_filetypes[filetype] = 1
@@ -858,13 +858,13 @@ endfunction
function! s:MarkdownRefreshSyntax(force) function! s:MarkdownRefreshSyntax(force)
if &filetype =~ 'markdown' && line('$') > 1 if &filetype =~# 'markdown' && line('$') > 1
call s:MarkdownHighlightSources(a:force) call s:MarkdownHighlightSources(a:force)
endif endif
endfunction endfunction
function! s:MarkdownClearSyntaxVariables() function! s:MarkdownClearSyntaxVariables()
if &filetype =~ 'markdown' if &filetype =~# 'markdown'
unlet! b:mkd_included_filetypes unlet! b:mkd_included_filetypes
endif endif
endfunction endfunction

View File

@@ -5,7 +5,6 @@ endif
scriptencoding utf-8 scriptencoding utf-8
" Vim filetype plugin file " Vim filetype plugin file
" Language: PlantUML " Language: PlantUML
" Maintainer: Anders Thøgersen <first name at bladre dot dk>
" License: VIM LICENSE " License: VIM LICENSE
if exists('b:loaded_plantuml_plugin') if exists('b:loaded_plantuml_plugin')

15
indent/basic.vim Normal file
View File

@@ -0,0 +1,15 @@
if polyglot#init#is_disabled(expand('<sfile>:p'), 'basic', 'indent/basic.vim')
finish
endif
" Vim indent file
" Language: BASIC (QuickBASIC 4.5)
" Maintainer: Doug Kearns <dougkearns@gmail.com>
" Last Change: 2022 Jan 24
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
finish
endif
runtime! indent/vb.vim

15
indent/freebasic.vim Normal file
View File

@@ -0,0 +1,15 @@
if polyglot#init#is_disabled(expand('<sfile>:p'), 'freebasic', 'indent/freebasic.vim')
finish
endif
" Vim indent file
" Language: FreeBASIC
" Maintainer: Doug Kearns <dougkearns@gmail.com>
" Last Change: 2022 Jan 24
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
finish
endif
runtime! indent/vb.vim

View File

@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'glsl', 'indent/glsl.vim')
endif endif
" Language: OpenGL Shading Language " Language: OpenGL Shading Language
" Maintainer: Sergey Tikhomirov <sergey@tikhomirov.io> " Maintainer: Sergii Tykhomyrov <sergii@tykhomyrov.net>
if exists("b:did_indent") if exists("b:did_indent")
finish finish

View File

@@ -2,7 +2,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'markdown', 'indent/markdown.v
finish finish
endif endif
if exists("b:did_indent") | finish | endif if exists('b:did_indent') | finish | endif
let b:did_indent = 1 let b:did_indent = 1
setlocal indentexpr=GetMarkdownIndent() setlocal indentexpr=GetMarkdownIndent()
@@ -12,7 +12,7 @@ setlocal autoindent
" Automatically continue blockquote on line break " Automatically continue blockquote on line break
setlocal formatoptions+=r setlocal formatoptions+=r
setlocal comments=b:> setlocal comments=b:>
if get(g:, "vim_markdown_auto_insert_bullets", 1) if get(g:, 'vim_markdown_auto_insert_bullets', 1)
" Do not automatically insert bullets when auto-wrapping with text-width " Do not automatically insert bullets when auto-wrapping with text-width
setlocal formatoptions-=c setlocal formatoptions-=c
" Accept various markers as bullets " Accept various markers as bullets
@@ -20,24 +20,24 @@ if get(g:, "vim_markdown_auto_insert_bullets", 1)
endif endif
" Only define the function once " Only define the function once
if exists("*GetMarkdownIndent") | finish | endif if exists('*GetMarkdownIndent') | finish | endif
function! s:IsMkdCode(lnum) function! s:IsMkdCode(lnum)
let name = synIDattr(synID(a:lnum, 1, 0), 'name') let name = synIDattr(synID(a:lnum, 1, 0), 'name')
return (name =~ '^mkd\%(Code$\|Snippet\)' || name != '' && name !~ '^\%(mkd\|html\)') return (name =~# '^mkd\%(Code$\|Snippet\)' || name !=# '' && name !~? '^\%(mkd\|html\)')
endfunction endfunction
function! s:IsLiStart(line) function! s:IsLiStart(line)
return a:line !~ '^ *\([*-]\)\%( *\1\)\{2}\%( \|\1\)*$' && return a:line !~# '^ *\([*-]\)\%( *\1\)\{2}\%( \|\1\)*$' &&
\ a:line =~ '^\s*[*+-] \+' \ a:line =~# '^\s*[*+-] \+'
endfunction endfunction
function! s:IsHeaderLine(line) function! s:IsHeaderLine(line)
return a:line =~ '^\s*#' return a:line =~# '^\s*#'
endfunction endfunction
function! s:IsBlankLine(line) function! s:IsBlankLine(line)
return a:line =~ '^$' return a:line =~# '^$'
endfunction endfunction
function! s:PrevNonBlank(lnum) function! s:PrevNonBlank(lnum)
@@ -52,7 +52,7 @@ function GetMarkdownIndent()
if v:lnum > 2 && s:IsBlankLine(getline(v:lnum - 1)) && s:IsBlankLine(getline(v:lnum - 2)) if v:lnum > 2 && s:IsBlankLine(getline(v:lnum - 1)) && s:IsBlankLine(getline(v:lnum - 2))
return 0 return 0
endif endif
let list_ind = get(g:, "vim_markdown_new_list_item_indent", 4) let list_ind = get(g:, 'vim_markdown_new_list_item_indent', 4)
" Find a non-blank line above the current line. " Find a non-blank line above the current line.
let lnum = s:PrevNonBlank(v:lnum - 1) let lnum = s:PrevNonBlank(v:lnum - 1)
" At the start of the file use zero indent. " At the start of the file use zero indent.

View File

@@ -5,7 +5,6 @@ endif
scriptencoding utf-8 scriptencoding utf-8
" Vim indent file " Vim indent file
" Language: PlantUML " Language: PlantUML
" Maintainer: Anders Thøgersen <first name at bladre dot dk>
" License: VIM LICENSE " License: VIM LICENSE
if exists('b:did_indent') if exists('b:did_indent')
@@ -21,7 +20,7 @@ if exists('*GetPlantUMLIndent')
finish finish
endif endif
let s:decIndent = '^\s*\%(end\|else\|}\)' let s:decIndent = '^\s*\%(end\|else\|fork again\|}\)'
function! GetPlantUMLIndent(...) abort function! GetPlantUMLIndent(...) abort
"for current line, use arg if given or v:lnum otherwise "for current line, use arg if given or v:lnum otherwise

View File

@@ -19,7 +19,7 @@ setlocal nosmartindent
" Now, set up our indentation expression and keys that trigger it. " Now, set up our indentation expression and keys that trigger it.
setlocal indentexpr=GetSolidityIndent() setlocal indentexpr=GetSolidityIndent()
setlocal indentkeys=0{,0},0),0],0\,,!^F,o,O,e setlocal indentkeys=0{,0},0),0],0\,,!^F,o,O,e,0*
" Only define the function once. " Only define the function once.
if exists("*GetSolidityIndent") if exists("*GetSolidityIndent")
@@ -41,7 +41,7 @@ let s:syng_strcom = 'string\|regex\|comment\c'
let s:syng_string = 'regex\c' let s:syng_string = 'regex\c'
" Regex of syntax group names that are strings or documentation. " Regex of syntax group names that are strings or documentation.
let s:syng_multiline = 'comment\c' let s:syng_multiline = 'comment\|natspecblock\c'
" Regex of syntax group names that are line comment. " Regex of syntax group names that are line comment.
let s:syng_linecom = 'linecomment\c' let s:syng_linecom = 'linecomment\c'

View File

@@ -3,16 +3,17 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'basic', 'syntax/basic.vim')
endif endif
" Vim syntax file " Vim syntax file
" Language: BASIC " Language: BASIC (QuickBASIC 4.5)
" Maintainer: Doug Kearns <dougkearns@gmail.com> " Maintainer: Doug Kearns <dougkearns@gmail.com>
" Previous Maintainer: Allan Kelly <allan@fruitloaf.co.uk> " Previous Maintainer: Allan Kelly <allan@fruitloaf.co.uk>
" Contributors: Thilo Six " Contributors: Thilo Six
" Last Change: 2015 Jan 10 " Last Change: 2021 Aug 08
" First version based on Micro$soft QBASIC circa 1989, as documented in " First version based on Micro$soft QBASIC circa 1989, as documented in
" 'Learn BASIC Now' by Halvorson&Rygmyr. Microsoft Press 1989. " 'Learn BASIC Now' by Halvorson&Rygmyr. Microsoft Press 1989.
" This syntax file not a complete implementation yet. Send suggestions to the "
" maintainer. " Second version attempts to match Microsoft QuickBASIC 4.5 while keeping FreeBASIC
" (-lang qb) and QB64 (excluding extensions) in mind. -- DJK
" Prelude {{{1 " Prelude {{{1
if exists("b:current_syntax") if exists("b:current_syntax")
@@ -22,154 +23,357 @@ endif
let s:cpo_save = &cpo let s:cpo_save = &cpo
set cpo&vim set cpo&vim
" Keywords {{{1 syn iskeyword @,48-57,.,!,#,%,&,$
syn keyword basicStatement BEEP beep Beep BLOAD bload Bload BSAVE bsave Bsave syn case ignore
syn keyword basicStatement CALL call Call ABSOLUTE absolute Absolute
syn keyword basicStatement CHAIN chain Chain CHDIR chdir Chdir
syn keyword basicStatement CIRCLE circle Circle CLEAR clear Clear
syn keyword basicStatement CLOSE close Close CLS cls Cls COLOR color Color
syn keyword basicStatement COM com Com COMMON common Common
syn keyword basicStatement CONST const Const DATA data Data
syn keyword basicStatement DECLARE declare Declare DEF def Def
syn keyword basicStatement DEFDBL defdbl Defdbl DEFINT defint Defint
syn keyword basicStatement DEFLNG deflng Deflng DEFSNG defsng Defsng
syn keyword basicStatement DEFSTR defstr Defstr DIM dim Dim
syn keyword basicStatement DO do Do LOOP loop Loop
syn keyword basicStatement DRAW draw Draw END end End
syn keyword basicStatement ENVIRON environ Environ ERASE erase Erase
syn keyword basicStatement ERROR error Error EXIT exit Exit
syn keyword basicStatement FIELD field Field FILES files Files
syn keyword basicStatement FOR for For NEXT next Next
syn keyword basicStatement FUNCTION function Function GET get Get
syn keyword basicStatement GOSUB gosub Gosub GOTO goto Goto
syn keyword basicStatement IF if If THEN then Then ELSE else Else
syn keyword basicStatement INPUT input Input INPUT# input# Input#
syn keyword basicStatement IOCTL ioctl Ioctl KEY key Key
syn keyword basicStatement KILL kill Kill LET let Let
syn keyword basicStatement LINE line Line LOCATE locate Locate
syn keyword basicStatement LOCK lock Lock UNLOCK unlock Unlock
syn keyword basicStatement LPRINT lprint Lprint USING using Using
syn keyword basicStatement LSET lset Lset MKDIR mkdir Mkdir
syn keyword basicStatement NAME name Name ON on On
syn keyword basicStatement ERROR error Error OPEN open Open
syn keyword basicStatement OPTION option Option BASE base Base
syn keyword basicStatement OUT out Out PAINT paint Paint
syn keyword basicStatement PALETTE palette Palette PCOPY pcopy Pcopy
syn keyword basicStatement PEN pen Pen PLAY play Play
syn keyword basicStatement PMAP pmap Pmap POKE poke Poke
syn keyword basicStatement PRESET preset Preset PRINT print Print
syn keyword basicStatement PRINT# print# Print# USING using Using
syn keyword basicStatement PSET pset Pset PUT put Put
syn keyword basicStatement RANDOMIZE randomize Randomize READ read Read
syn keyword basicStatement REDIM redim Redim RESET reset Reset
syn keyword basicStatement RESTORE restore Restore RESUME resume Resume
syn keyword basicStatement RETURN return Return RMDIR rmdir Rmdir
syn keyword basicStatement RSET rset Rset RUN run Run
syn keyword basicStatement SEEK seek Seek SELECT select Select
syn keyword basicStatement CASE case Case SHARED shared Shared
syn keyword basicStatement SHELL shell Shell SLEEP sleep Sleep
syn keyword basicStatement SOUND sound Sound STATIC static Static
syn keyword basicStatement STOP stop Stop STRIG strig Strig
syn keyword basicStatement SUB sub Sub SWAP swap Swap
syn keyword basicStatement SYSTEM system System TIMER timer Timer
syn keyword basicStatement TROFF troff Troff TRON tron Tron
syn keyword basicStatement TYPE type Type UNLOCK unlock Unlock
syn keyword basicStatement VIEW view View WAIT wait Wait
syn keyword basicStatement WHILE while While WEND wend Wend
syn keyword basicStatement WIDTH width Width WINDOW window Window
syn keyword basicStatement WRITE write Write DATE$ date$ Date$
syn keyword basicStatement MID$ mid$ Mid$ TIME$ time$ Time$
syn keyword basicFunction ABS abs Abs ASC asc Asc " Whitespace Errors {{{1
syn keyword basicFunction ATN atn Atn CDBL cdbl Cdbl if exists("basic_space_errors")
syn keyword basicFunction CINT cint Cint CLNG clng Clng if !exists("basic_no_trail_space_error")
syn keyword basicFunction COS cos Cos CSNG csng Csng syn match basicSpaceError display excludenl "\s\+$"
syn keyword basicFunction CSRLIN csrlin Csrlin CVD cvd Cvd endif
syn keyword basicFunction CVDMBF cvdmbf Cvdmbf CVI cvi Cvi if !exists("basic_no_tab_space_error")
syn keyword basicFunction CVL cvl Cvl CVS cvs Cvs syn match basicSpaceError display " \+\t"me=e-1
syn keyword basicFunction CVSMBF cvsmbf Cvsmbf EOF eof Eof endif
syn keyword basicFunction ERDEV erdev Erdev ERL erl Erl endif
syn keyword basicFunction ERR err Err EXP exp Exp
syn keyword basicFunction FILEATTR fileattr Fileattr FIX fix Fix " Comment Errors {{{1
syn keyword basicFunction FRE fre Fre FREEFILE freefile Freefile if !exists("basic_no_comment_errors")
syn keyword basicFunction INP inp Inp INSTR instr Instr syn match basicCommentError "\<REM\>.*"
syn keyword basicFunction INT int Int LBOUND lbound Lbound endif
syn keyword basicFunction LEN len Len LOC loc Loc
syn keyword basicFunction LOF lof Lof LOG log Log " Not Top Cluster {{{1
syn keyword basicFunction LPOS lpos Lpos PEEK peek Peek syn cluster basicNotTop contains=@basicLineIdentifier,basicDataString,basicDataSeparator,basicTodo
syn keyword basicFunction PEN pen Pen POINT point Point
syn keyword basicFunction POS pos Pos RND rnd Rnd " Statements {{{1
syn keyword basicFunction SADD sadd Sadd SCREEN screen Screen
syn keyword basicFunction SEEK seek Seek SETMEM setmem Setmem syn cluster basicStatements contains=basicStatement,basicDataStatement,basicMetaRemStatement,basicPutStatement,basicRemStatement
syn keyword basicFunction SGN sgn Sgn SIN sin Sin
syn keyword basicFunction SPC spc Spc SQR sqr Sqr let s:statements =<< trim EOL " {{{2
syn keyword basicFunction STICK stick Stick STRIG strig Strig beep
syn keyword basicFunction TAB tab Tab TAN tan Tan bload
syn keyword basicFunction UBOUND ubound Ubound VAL val Val bsave
syn keyword basicFunction VALPTR valptr Valptr VALSEG valseg Valseg call
syn keyword basicFunction VARPTR varptr Varptr VARSEG varseg Varseg calls
syn keyword basicFunction CHR$ Chr$ chr$ COMMAND$ command$ Command$ case
syn keyword basicFunction DATE$ date$ Date$ ENVIRON$ environ$ Environ$ chain
syn keyword basicFunction ERDEV$ erdev$ Erdev$ HEX$ hex$ Hex$ chdir
syn keyword basicFunction INKEY$ inkey$ Inkey$ INPUT$ input$ Input$ circle
syn keyword basicFunction IOCTL$ ioctl$ Ioctl$ LCASES$ lcases$ Lcases$ clear
syn keyword basicFunction LAFT$ laft$ Laft$ LTRIM$ ltrim$ Ltrim$ close
syn keyword basicFunction MID$ mid$ Mid$ MKDMBF$ mkdmbf$ Mkdmbf$ cls
syn keyword basicFunction MKD$ mkd$ Mkd$ MKI$ mki$ Mki$ color
syn keyword basicFunction MKL$ mkl$ Mkl$ MKSMBF$ mksmbf$ Mksmbf$ com
syn keyword basicFunction MKS$ mks$ Mks$ OCT$ oct$ Oct$ common
syn keyword basicFunction RIGHT$ right$ Right$ RTRIM$ rtrim$ Rtrim$ const
syn keyword basicFunction SPACE$ space$ Space$ STR$ str$ Str$ declare
syn keyword basicFunction STRING$ string$ String$ TIME$ time$ Time$ def
syn keyword basicFunction UCASE$ ucase$ Ucase$ VARPTR$ varptr$ Varptr$ def\s\+seg
defdbl
defint
deflng
defsng
defstr
dim
do
draw
elseif
end
end\s\+\%(def\|function\|if\|select\|sub\|type\)
environ
erase
error
exit\s\+\%(def\|do\|for\|function\|sub\)
field
files
for
function
get
gosub
goto
if
input
ioctl
key
kill
let
line
line\s\+input
locate
lock
loop
lprint
lset
mkdir
name
next
on
on\s\+error
on\s\+uevent
open
open\s\+com
option
out
paint
palette
palette\s\+using
pcopy
pen
pmap
poke
preset
print
pset
randomize
read
redim
reset
restore
resume
return
rmdir
rset
run
select\s\+case
shared
shell
sleep
sound
static
stop
strig
sub
swap
system
troff
tron
type
uevent
unlock
using
view
view\s\+print
wait
wend
while
width
window
write
EOL
" }}}
for s in s:statements
exe 'syn match basicStatement "\<' .. s .. '\>" contained'
endfor
syn match basicStatement "\<\%(then\|else\)\>" nextgroup=@basicStatements skipwhite
" DATA Statement
syn match basicDataSeparator "," contained
syn region basicDataStatement matchgroup=basicStatement start="\<data\>" matchgroup=basicStatementSeparator end=":\|$" contained contains=basicDataSeparator,basicDataString,basicNumber,basicFloat,basicString
if !exists("basic_no_data_fold")
syn region basicMultilineData start="^\s*\<data\>.*\n\%(^\s*\<data\>\)\@=" end="^\s*\<data\>.*\n\%(^\s*\<data\>\)\@!" contains=basicDataStatement transparent fold keepend
endif
" PUT File I/O and Graphics statements - needs special handling for graphics
" action verbs
syn match basicPutAction "\<\%(pset\|preset\|and\|or\|xor\)\>" contained
syn region basicPutStatement matchgroup=basicStatement start="\<put\>" matchgroup=basicStatementSeparator end=":\|$" contained contains=basicKeyword,basicPutAction,basicFilenumber
" Keywords {{{1
let s:keywords =<< trim EOL " {{{2
absolute
access
alias
append
as
base
binary
byval
cdecl
com
def
do
for
function
gosub
goto
input
int86old
int86xold
interrupt
interruptx
is
key
len
list
local
lock
lprint
next
off
on
output
pen
play
random
read
resume
screen
seg
shared
signal
static
step
stop
strig
sub
timer
to
until
using
while
write
EOL
" }}}
for k in s:keywords
exe 'syn match basicKeyword "\<' .. k .. '\>"'
endfor
" Functions {{{1
syn keyword basicFunction abs asc atn cdbl chr$ cint clng command$ cos csng
syn keyword basicFunction csrlin cvd cvdmbf cvi cvl cvs cvsmbf environ$ eof
syn keyword basicFunction erdev erdev$ erl err exp fileattr fix fre freefile
syn keyword basicFunction hex$ inkey$ inp input$ instr int ioctl$ left$ lbound
syn keyword basicFunction lcase$ len loc lof log lpos ltrim$ mkd$ mkdmbf$ mki$
syn keyword basicFunction mkl$ mks$ mksmbf$ oct$ peek pen point pos right$ rnd
syn keyword basicFunction rtrim$ sadd setmem sgn sin space$ spc sqr stick str$
syn keyword basicFunction strig string$ tab tan ubound ucase$ val valptr
syn keyword basicFunction valseg varptr varptr$ varseg
" Functions and statements (same name) {{{1
syn match basicStatement "\<\%(date\$\|mid\$\|play\|screen\|seek\|time\$\|timer\)\>" contained
syn match basicFunction "\<\%(date\$\|mid\$\|play\|screen\|seek\|time\$\|timer\)\>"
" Types {{{1
syn keyword basicType integer long single double string any
" Strings {{{1
" Unquoted DATA strings - anything except [:,] and leading or trailing whitespace
" Needs lower priority than numbers
syn match basicDataString "[^[:space:],:]\+\%(\s\+[^[:space:],:]\+\)*" contained
syn region basicString start=+"+ end=+"+ oneline
" Booleans {{{1
if exists("basic_booleans")
syn keyword basicBoolean true false
endif
" Numbers {{{1 " Numbers {{{1
" Integer number, or floating point number without a dot.
syn match basicNumber "\<\d\+\>"
" Floating point number, with dot
syn match basicNumber "\<\d\+\.\d*\>"
" Floating point number, starting with a dot
syn match basicNumber "\.\d\+\>"
" String and Character constants {{{1 " Integers
syn match basicSpecial "\\\d\d\d\|\\." contained syn match basicNumber "-\=&o\=\o\+[%&]\=\>"
syn region basicString start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=basicSpecial syn match basicNumber "-\=&h\x\+[%&]\=\>"
syn match basicNumber "-\=\<\d\+[%&]\=\>"
" Line numbers {{{1 " Floats
syn region basicLineNumber start="^\d" end="\s" syn match basicFloat "-\=\<\d\+\.\=\d*\%(\%([ed][+-]\=\d*\)\|[!#]\)\=\>"
syn match basicFloat "-\=\<\.\d\+\%(\%([ed][+-]\=\d*\)\|[!#]\)\=\>"
" Data-type suffixes {{{1 " Statement anchors {{{1
syn match basicTypeSpecifier "[a-zA-Z0-9][$%&!#]"ms=s+1 syn match basicLineStart "^" nextgroup=@basicStatements,@basicLineIdentifier skipwhite
" Used with OPEN statement syn match basicStatementSeparator ":" nextgroup=@basicStatements skipwhite
" Line numbers and labels {{{1
" QuickBASIC limits these to 65,529 and 40 chars respectively
syn match basicLineNumber "\d\+" nextgroup=@basicStatements skipwhite contained
syn match basicLineLabel "\a[[:alnum:]]*\ze\s*:" nextgroup=@basicStatements skipwhite contained
syn cluster basicLineIdentifier contains=basicLineNumber,basicLineLabel
" Line Continuation {{{1
syn match basicLineContinuation "\s*\zs_\ze\s*$"
" Type suffixes {{{1
if exists("basic_type_suffixes")
syn match basicTypeSuffix "\a[[:alnum:].]*\zs[$%&!#]"
endif
" File numbers {{{1
syn match basicFilenumber "#\d\+" syn match basicFilenumber "#\d\+"
syn match basicFilenumber "#\a[[:alnum:].]*[%&!#]\="
" Mathematical operators {{{1 " Operators {{{1
" syn match basicMathsOperator "[<>+\*^/\\=-]" if exists("basic_operators")
syn match basicMathsOperator "-\|=\|[:<>+\*^/\\]\|AND\|OR" syn match basicArithmeticOperator "[-+*/\\^]"
syn match basicRelationalOperator "<>\|<=\|>=\|[><=]"
endif
syn match basicLogicalOperator "\<\%(not\|and\|or\|xor\|eqv\|imp\)\>"
syn match basicArithmeticOperator "\<mod\>"
" Metacommands {{{1
" Note: No trailing word boundaries. Text may be freely mixed however there
" must be only leading whitespace prior to the first metacommand
syn match basicMetacommand "$INCLUDE\s*:\s*'[^']\+'" contained containedin=@basicMetaComments
syn match basicMetacommand "$\%(DYNAMIC\|STATIC\)" contained containedin=@basicMetaComments
" Comments {{{1 " Comments {{{1
syn keyword basicTodo TODO FIXME XXX NOTE contained syn keyword basicTodo TODO FIXME XXX NOTE contained
syn region basicComment start="^\s*\zsREM\>" start="\%(:\s*\)\@<=REM\>" end="$" contains=basicTodo
syn region basicComment start="'" end="$" contains=basicTodo syn region basicRemStatement matchgroup=basicStatement start="REM\>" end="$" contains=basicTodo,@Spell contained
syn region basicComment start="'" end="$" contains=basicTodo,@Spell
if !exists("basic_no_comment_fold")
syn region basicMultilineComment start="^\s*'.*\n\%(\s*'\)\@=" end="^\s*'.*\n\%(\s*'\)\@!" contains=@basicComments transparent fold keepend
endif
" Metacommands
syn region basicMetaRemStatement matchgroup=basicStatement start="REM\>\s*\$\@=" end="$" contains=basicTodo contained
syn region basicMetaComment start="'\s*\$\@=" end="$" contains=basicTodo
syn cluster basicMetaComments contains=basicMetaComment,basicMetaRemStatement
syn cluster basicComments contains=basicComment,basicMetaComment
"syn sync ccomment basicComment "syn sync ccomment basicComment
" Default Highlighting {{{1 " Default Highlighting {{{1
hi def link basicLabel Label hi def link basicArithmeticOperator basicOperator
hi def link basicConditional Conditional hi def link basicBoolean Boolean
hi def link basicRepeat Repeat hi def link basicComment Comment
hi def link basicLineNumber Comment hi def link basicCommentError Error
hi def link basicDataString basicString
hi def link basicFilenumber basicTypeSuffix " TODO: better group
hi def link basicFloat Float
hi def link basicFunction Identifier
hi def link basicKeyword Keyword
hi def link basicLineIdentifier LineNr
hi def link basicLineContinuation Special
hi def link basicLineLabel basicLineIdentifier
hi def link basicLineNumber basicLineIdentifier
hi def link basicLogicalOperator basicOperator
hi def link basicMetacommand SpecialComment
hi def link basicMetaComment Comment
hi def link basicMetaRemStatement Comment
hi def link basicNumber Number hi def link basicNumber Number
hi def link basicError Error hi def link basicOperator Operator
hi def link basicPutAction Keyword
hi def link basicRelationalOperator basicOperator
hi def link basicRemStatement Comment
hi def link basicSpaceError Error
hi def link basicStatementSeparator Special
hi def link basicStatement Statement hi def link basicStatement Statement
hi def link basicString String hi def link basicString String
hi def link basicComment Comment
hi def link basicSpecial Special
hi def link basicTodo Todo hi def link basicTodo Todo
hi def link basicFunction Identifier hi def link basicType Type
hi def link basicTypeSpecifier Type hi def link basicTypeSuffix Special
hi def link basicFilenumber basicTypeSpecifier if exists("basic_legacy_syntax_groups")
"hi basicMathsOperator term=bold cterm=bold gui=bold hi def link basicTypeSpecifier Type
hi def link basicTypeSuffix basicTypeSpecifier
endif
" Postscript {{{1 " Postscript {{{1
let b:current_syntax = "basic" let b:current_syntax = "basic"

File diff suppressed because one or more lines are too long

View File

@@ -380,13 +380,14 @@ syn cluster crystalMacroGroup add=crystalMacroKeyword
" Comments and Documentation " Comments and Documentation
syn match crystalSharpBang "\%^#!.*" display syn match crystalSharpBang "\%^#!.*" display
syn keyword crystalTodo FIXME NOTE TODO OPTIMIZE XXX todo contained syn keyword crystalTodo FIXME NOTE TODO OPTIMIZE XXX todo contained
syn match crystalCommentDirective ":\%(nodoc\|nodoc\|inherit\):" contained
if exists('g:main_syntax') && g:main_syntax ==# 'ecrystal' if exists('g:main_syntax') && g:main_syntax ==# 'ecrystal'
" eCrystal tags can contain Crystal comments, so we need to modify the " eCrystal tags can contain Crystal comments, so we need to modify the
" pattern for comments so that it does not consume delimiters " pattern for comments so that it does not consume delimiters
syn match crystalComment "#.*\ze\%($\|-\=%>\)" contains=crystalSharpBang,crystalSpaceError,crystalTodo,@Spell syn match crystalComment "#.*\ze\%($\|-\=%>\)" contains=crystalSharpBang,crystalSpaceError,crystalTodo,crystalCommentDirective,@Spell
else else
syn match crystalComment "#.*" contains=crystalSharpBang,crystalSpaceError,crystalTodo,@Spell syn match crystalComment "#.*" contains=crystalSharpBang,crystalSpaceError,crystalTodo,crystalCommentDirective,@Spell
endif endif
SynFold '#' syn region crystalMultilineComment start="\%(\%(^\s*#.*\n\)\@<!\%(^\s*#.*\n\)\)\%(\(^\s*#.*\n\)\{1,}\)\@=" end="\%(^\s*#.*\n\)\@<=\%(^\s*#.*\n\)\%(^\s*#\)\@!" contains=crystalComment transparent keepend SynFold '#' syn region crystalMultilineComment start="\%(\%(^\s*#.*\n\)\@<!\%(^\s*#.*\n\)\)\%(\(^\s*#.*\n\)\{1,}\)\@=" end="\%(^\s*#.*\n\)\@<=\%(^\s*#.*\n\)\%(^\s*#\)\@!" contains=crystalComment transparent keepend
@@ -456,6 +457,7 @@ hi def link crystalPseudoVariable Constant
hi def link crystalCharLiteral Character hi def link crystalCharLiteral Character
hi def link crystalComment Comment hi def link crystalComment Comment
hi def link crystalTodo Todo hi def link crystalTodo Todo
hi def link crystalCommentDirective SpecialComment
hi def link crystalStringEscape Special hi def link crystalStringEscape Special
hi def link crystalInterpolationDelim Delimiter hi def link crystalInterpolationDelim Delimiter
hi def link crystalNoInterpolation crystalString hi def link crystalNoInterpolation crystalString

View File

@@ -63,6 +63,8 @@ syn cluster eelixirRegions contains=eelixirBlock,surfaceExpression,eelixirExpres
exe 'syn region eelixirExpression matchgroup=eelixirDelimiter start="<%" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend' exe 'syn region eelixirExpression matchgroup=eelixirDelimiter start="<%" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region eelixirExpression matchgroup=eelixirDelimiter start="<%=" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend' exe 'syn region eelixirExpression matchgroup=eelixirDelimiter start="<%=" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{{" end="}}" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend' exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{{" end="}}" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{" end="}" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region surfaceExpression matchgroup=surfaceDelimiter start="{" end="}" skip="#{[^}]*}" contains=@elixirTop containedin=htmlValue keepend'
exe 'syn region eelixirQuote matchgroup=eelixirDelimiter start="<%%" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend' exe 'syn region eelixirQuote matchgroup=eelixirDelimiter start="<%%" end="%\@<!%>" contains=@elixirTop containedin=ALLBUT,@eelixirRegions keepend'
exe 'syn region eelixirComment matchgroup=eelixirDelimiter start="<%#" end="%\@<!%>" contains=elixirTodo,@Spell containedin=ALLBUT,@eelixirRegions keepend' exe 'syn region eelixirComment matchgroup=eelixirDelimiter start="<%#" end="%\@<!%>" contains=elixirTodo,@Spell containedin=ALLBUT,@eelixirRegions keepend'

View File

@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'glsl', 'syntax/glsl.vim')
endif endif
" Language: OpenGL Shading Language " Language: OpenGL Shading Language
" Maintainer: Sergey Tikhomirov <sergey@tikhomirov.io> " Maintainer: Sergii Tykhomyrov <sergii@tykhomyrov.net>
if exists("b:current_syntax") && b:current_syntax == "glsl" if exists("b:current_syntax") && b:current_syntax == "glsl"
finish finish
@@ -51,6 +51,7 @@ syn keyword glslStructure struct nextgroup=glslIdentifier skipwhite skipempty
syn match glslIdentifier contains=glslIdentifierPrime "\%([a-zA-Z_]\)\%([a-zA-Z0-9_]\)*" display contained syn match glslIdentifier contains=glslIdentifierPrime "\%([a-zA-Z_]\)\%([a-zA-Z0-9_]\)*" display contained
" Types " Types
syn keyword glslType accelerationStructureEXT
syn keyword glslType atomic_uint syn keyword glslType atomic_uint
syn keyword glslType bool syn keyword glslType bool
syn keyword glslType bvec2 syn keyword glslType bvec2
@@ -122,6 +123,7 @@ syn keyword glslType mat4
syn keyword glslType mat4x2 syn keyword glslType mat4x2
syn keyword glslType mat4x3 syn keyword glslType mat4x3
syn keyword glslType mat4x4 syn keyword glslType mat4x4
syn keyword glslType rayQueryEXT
syn keyword glslType sampler1D syn keyword glslType sampler1D
syn keyword glslType sampler1DArray syn keyword glslType sampler1DArray
syn keyword glslType sampler1DArrayShadow syn keyword glslType sampler1DArrayShadow
@@ -176,6 +178,8 @@ syn keyword glslQualifier align
syn keyword glslQualifier attribute syn keyword glslQualifier attribute
syn keyword glslQualifier binding syn keyword glslQualifier binding
syn keyword glslQualifier buffer syn keyword glslQualifier buffer
syn keyword glslQualifier callableDataEXT
syn keyword glslQualifier callableDataInEXT
syn keyword glslQualifier ccw syn keyword glslQualifier ccw
syn keyword glslQualifier centroid syn keyword glslQualifier centroid
syn keyword glslQualifier centroid varying syn keyword glslQualifier centroid varying
@@ -193,6 +197,7 @@ syn keyword glslQualifier flat
syn keyword glslQualifier fractional_even_spacing syn keyword glslQualifier fractional_even_spacing
syn keyword glslQualifier fractional_odd_spacing syn keyword glslQualifier fractional_odd_spacing
syn keyword glslQualifier highp syn keyword glslQualifier highp
syn keyword glslQualifier hitAttributeEXT
syn keyword glslQualifier in syn keyword glslQualifier in
syn keyword glslQualifier index syn keyword glslQualifier index
syn keyword glslQualifier inout syn keyword glslQualifier inout
@@ -210,6 +215,7 @@ syn keyword glslQualifier location
syn keyword glslQualifier lowp syn keyword glslQualifier lowp
syn keyword glslQualifier max_vertices syn keyword glslQualifier max_vertices
syn keyword glslQualifier mediump syn keyword glslQualifier mediump
syn keyword glslQualifier nonuniformEXT
syn keyword glslQualifier noperspective syn keyword glslQualifier noperspective
syn keyword glslQualifier offset syn keyword glslQualifier offset
syn keyword glslQualifier origin_upper_left syn keyword glslQualifier origin_upper_left
@@ -235,6 +241,8 @@ syn keyword glslQualifier r8
syn keyword glslQualifier r8_snorm syn keyword glslQualifier r8_snorm
syn keyword glslQualifier r8i syn keyword glslQualifier r8i
syn keyword glslQualifier r8ui syn keyword glslQualifier r8ui
syn keyword glslQualifier rayPayloadEXT
syn keyword glslQualifier rayPayloadInEXT
syn keyword glslQualifier readonly syn keyword glslQualifier readonly
syn keyword glslQualifier restrict syn keyword glslQualifier restrict
syn keyword glslQualifier rg16 syn keyword glslQualifier rg16
@@ -265,6 +273,7 @@ syn keyword glslQualifier rgba8i
syn keyword glslQualifier rgba8ui syn keyword glslQualifier rgba8ui
syn keyword glslQualifier row_major syn keyword glslQualifier row_major
syn keyword glslQualifier sample syn keyword glslQualifier sample
syn keyword glslQualifier shaderRecordEXT
syn keyword glslQualifier shared syn keyword glslQualifier shared
syn keyword glslQualifier smooth syn keyword glslQualifier smooth
syn keyword glslQualifier std140 syn keyword glslQualifier std140
@@ -279,11 +288,13 @@ syn keyword glslQualifier vertices
syn keyword glslQualifier volatile syn keyword glslQualifier volatile
syn keyword glslQualifier writeonly syn keyword glslQualifier writeonly
syn keyword glslQualifier xfb_buffer syn keyword glslQualifier xfb_buffer
syn keyword glslQualifier xfb_stride
syn keyword glslQualifier xfb_offset syn keyword glslQualifier xfb_offset
syn keyword glslQualifier xfb_stride
" Built-in Constants " Built-in Constants
syn keyword glslBuiltinConstant gl_CullDistance syn keyword glslBuiltinConstant gl_CullDistance
syn keyword glslBuiltinConstant gl_HitKindBackFacingTriangleEXT
syn keyword glslBuiltinConstant gl_HitKindFrontFacingTriangleEXT
syn keyword glslBuiltinConstant gl_MaxAtomicCounterBindings syn keyword glslBuiltinConstant gl_MaxAtomicCounterBindings
syn keyword glslBuiltinConstant gl_MaxAtomicCounterBufferSize syn keyword glslBuiltinConstant gl_MaxAtomicCounterBufferSize
syn keyword glslBuiltinConstant gl_MaxClipDistances syn keyword glslBuiltinConstant gl_MaxClipDistances
@@ -363,6 +374,20 @@ syn keyword glslBuiltinConstant gl_MaxVertexUniformComponents
syn keyword glslBuiltinConstant gl_MaxVertexUniformVectors syn keyword glslBuiltinConstant gl_MaxVertexUniformVectors
syn keyword glslBuiltinConstant gl_MaxViewports syn keyword glslBuiltinConstant gl_MaxViewports
syn keyword glslBuiltinConstant gl_MinProgramTexelOffset syn keyword glslBuiltinConstant gl_MinProgramTexelOffset
syn keyword glslBuiltinConstant gl_RayFlagsCullBackFacingTrianglesEXT
syn keyword glslBuiltinConstant gl_RayFlagsCullFrontFacingTrianglesEXT
syn keyword glslBuiltinConstant gl_RayFlagsCullNoOpaqueEXT
syn keyword glslBuiltinConstant gl_RayFlagsCullOpaqueEXT
syn keyword glslBuiltinConstant gl_RayFlagsNoOpaqueEXT
syn keyword glslBuiltinConstant gl_RayFlagsNoneEXT
syn keyword glslBuiltinConstant gl_RayFlagsOpaqueEXT
syn keyword glslBuiltinConstant gl_RayFlagsSkipClosestHitShaderEXT
syn keyword glslBuiltinConstant gl_RayFlagsTerminateOnFirstHitEXT
syn keyword glslBuiltinConstant gl_RayQueryCandidateIntersectionAABBEXT
syn keyword glslBuiltinConstant gl_RayQueryCandidateIntersectionTriangleEXT
syn keyword glslBuiltinConstant gl_RayQueryCommittedIntersectionGeneratedEXT
syn keyword glslBuiltinConstant gl_RayQueryCommittedIntersectionNoneEXT
syn keyword glslBuiltinConstant gl_RayQueryCommittedIntersectionTriangleEXT
" Built-in Variables " Built-in Variables
syn keyword glslBuiltinVariable gl_BackColor syn keyword glslBuiltinVariable gl_BackColor
@@ -393,10 +418,18 @@ syn keyword glslBuiltinVariable gl_FrontLightModelProduct
syn keyword glslBuiltinVariable gl_FrontLightProduct syn keyword glslBuiltinVariable gl_FrontLightProduct
syn keyword glslBuiltinVariable gl_FrontMaterial syn keyword glslBuiltinVariable gl_FrontMaterial
syn keyword glslBuiltinVariable gl_FrontSecondaryColor syn keyword glslBuiltinVariable gl_FrontSecondaryColor
syn keyword glslBuiltinVariable gl_GeometryIndexEXT
syn keyword glslBuiltinVariable gl_GlobalInvocationID syn keyword glslBuiltinVariable gl_GlobalInvocationID
syn keyword glslBuiltinVariable gl_HelperInvocation syn keyword glslBuiltinVariable gl_HelperInvocation
syn keyword glslBuiltinVariable gl_HitKindEXT
syn keyword glslBuiltinVariable gl_HitTEXT
syn keyword glslBuiltinVariable gl_IncomingRayFlagsEXT
syn keyword glslBuiltinVariable gl_InstanceCustomIndexEXT
syn keyword glslBuiltinVariable gl_InstanceID
syn keyword glslBuiltinVariable gl_InstanceID syn keyword glslBuiltinVariable gl_InstanceID
syn keyword glslBuiltinVariable gl_InvocationID syn keyword glslBuiltinVariable gl_InvocationID
syn keyword glslBuiltinVariable gl_LaunchIDEXT
syn keyword glslBuiltinVariable gl_LaunchSizeEXT
syn keyword glslBuiltinVariable gl_Layer syn keyword glslBuiltinVariable gl_Layer
syn keyword glslBuiltinVariable gl_LightModel syn keyword glslBuiltinVariable gl_LightModel
syn keyword glslBuiltinVariable gl_LightSource syn keyword glslBuiltinVariable gl_LightSource
@@ -427,17 +460,24 @@ syn keyword glslBuiltinVariable gl_ObjectPlaneQ
syn keyword glslBuiltinVariable gl_ObjectPlaneR syn keyword glslBuiltinVariable gl_ObjectPlaneR
syn keyword glslBuiltinVariable gl_ObjectPlaneS syn keyword glslBuiltinVariable gl_ObjectPlaneS
syn keyword glslBuiltinVariable gl_ObjectPlaneT syn keyword glslBuiltinVariable gl_ObjectPlaneT
syn keyword glslBuiltinVariable gl_ObjectRayDirectionEXT
syn keyword glslBuiltinVariable gl_ObjectRayOriginEXT
syn keyword glslBuiltinVariable gl_ObjectToWorld3x4EXT
syn keyword glslBuiltinVariable gl_ObjectToWorldEXT
syn keyword glslBuiltinVariable gl_PatchVerticesIn syn keyword glslBuiltinVariable gl_PatchVerticesIn
syn keyword glslBuiltinVariable gl_Point syn keyword glslBuiltinVariable gl_Point
syn keyword glslBuiltinVariable gl_PointCoord syn keyword glslBuiltinVariable gl_PointCoord
syn keyword glslBuiltinVariable gl_PointSize syn keyword glslBuiltinVariable gl_PointSize
syn keyword glslBuiltinVariable gl_Position syn keyword glslBuiltinVariable gl_Position
syn keyword glslBuiltinVariable gl_PrimitiveID syn keyword glslBuiltinVariable gl_PrimitiveID
syn keyword glslBuiltinVariable gl_PrimitiveID
syn keyword glslBuiltinVariable gl_PrimitiveIDIn syn keyword glslBuiltinVariable gl_PrimitiveIDIn
syn keyword glslBuiltinVariable gl_ProjectionMatrix syn keyword glslBuiltinVariable gl_ProjectionMatrix
syn keyword glslBuiltinVariable gl_ProjectionMatrixInverse syn keyword glslBuiltinVariable gl_ProjectionMatrixInverse
syn keyword glslBuiltinVariable gl_ProjectionMatrixInverseTranspose syn keyword glslBuiltinVariable gl_ProjectionMatrixInverseTranspose
syn keyword glslBuiltinVariable gl_ProjectionMatrixTranspose syn keyword glslBuiltinVariable gl_ProjectionMatrixTranspose
syn keyword glslBuiltinVariable gl_RayTmaxEXT
syn keyword glslBuiltinVariable gl_RayTminEXT
syn keyword glslBuiltinVariable gl_SampleID syn keyword glslBuiltinVariable gl_SampleID
syn keyword glslBuiltinVariable gl_SampleMask syn keyword glslBuiltinVariable gl_SampleMask
syn keyword glslBuiltinVariable gl_SampleMaskIn syn keyword glslBuiltinVariable gl_SampleMaskIn
@@ -458,6 +498,10 @@ syn keyword glslBuiltinVariable gl_VertexIndex
syn keyword glslBuiltinVariable gl_ViewportIndex syn keyword glslBuiltinVariable gl_ViewportIndex
syn keyword glslBuiltinVariable gl_WorkGroupID syn keyword glslBuiltinVariable gl_WorkGroupID
syn keyword glslBuiltinVariable gl_WorkGroupSize syn keyword glslBuiltinVariable gl_WorkGroupSize
syn keyword glslBuiltinVariable gl_WorldRayDirectionEXT
syn keyword glslBuiltinVariable gl_WorldRayOriginEXT
syn keyword glslBuiltinVariable gl_WorldToObject3x4EXT
syn keyword glslBuiltinVariable gl_WorldToObjectEXT
syn keyword glslBuiltinVariable gl_in syn keyword glslBuiltinVariable gl_in
syn keyword glslBuiltinVariable gl_out syn keyword glslBuiltinVariable gl_out
@@ -507,6 +551,7 @@ syn keyword glslBuiltinFunction determinant
syn keyword glslBuiltinFunction distance syn keyword glslBuiltinFunction distance
syn keyword glslBuiltinFunction dot syn keyword glslBuiltinFunction dot
syn keyword glslBuiltinFunction equal syn keyword glslBuiltinFunction equal
syn keyword glslBuiltinFunction executeCallableEXT
syn keyword glslBuiltinFunction exp syn keyword glslBuiltinFunction exp
syn keyword glslBuiltinFunction exp2 syn keyword glslBuiltinFunction exp2
syn keyword glslBuiltinFunction faceforward syn keyword glslBuiltinFunction faceforward
@@ -525,6 +570,7 @@ syn keyword glslBuiltinFunction fwidthFine
syn keyword glslBuiltinFunction greaterThan syn keyword glslBuiltinFunction greaterThan
syn keyword glslBuiltinFunction greaterThanEqual syn keyword glslBuiltinFunction greaterThanEqual
syn keyword glslBuiltinFunction groupMemoryBarrier syn keyword glslBuiltinFunction groupMemoryBarrier
syn keyword glslBuiltinFunction ignoreIntersectionEXT
syn keyword glslBuiltinFunction imageAtomicAdd syn keyword glslBuiltinFunction imageAtomicAdd
syn keyword glslBuiltinFunction imageAtomicAnd syn keyword glslBuiltinFunction imageAtomicAnd
syn keyword glslBuiltinFunction imageAtomicCompSwap syn keyword glslBuiltinFunction imageAtomicCompSwap
@@ -578,8 +624,32 @@ syn keyword glslBuiltinFunction packUnorm2x16
syn keyword glslBuiltinFunction packUnorm4x8 syn keyword glslBuiltinFunction packUnorm4x8
syn keyword glslBuiltinFunction pow syn keyword glslBuiltinFunction pow
syn keyword glslBuiltinFunction radians syn keyword glslBuiltinFunction radians
syn keyword glslBuiltinFunction rayQueryConfirmIntersectionEXT
syn keyword glslBuiltinFunction rayQueryGenerateIntersectionEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionBarycentricsEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionCandidateAABBOpaqueEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionFrontFaceEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionGeometryIndexEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionInstanceCustomIndexEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionInstanceIdEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionInstanceShaderBindingTableRecordOffsetEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionObjectRayDirectionEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionObjectRayOriginEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionObjectToWorldEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionPrimitiveIndexEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionTEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionTypeEXT
syn keyword glslBuiltinFunction rayQueryGetIntersectionWorldToObjectEXT
syn keyword glslBuiltinFunction rayQueryGetRayFlagsEXT
syn keyword glslBuiltinFunction rayQueryGetRayTMinEXT
syn keyword glslBuiltinFunction rayQueryGetWorldRayDirectionEXT
syn keyword glslBuiltinFunction rayQueryGetWorldRayOriginEXT
syn keyword glslBuiltinFunction rayQueryInitializeEXT
syn keyword glslBuiltinFunction rayQueryProceedEXT
syn keyword glslBuiltinFunction rayQueryTerminateEXT
syn keyword glslBuiltinFunction reflect syn keyword glslBuiltinFunction reflect
syn keyword glslBuiltinFunction refract syn keyword glslBuiltinFunction refract
syn keyword glslBuiltinFunction reportIntersectionEXT
syn keyword glslBuiltinFunction round syn keyword glslBuiltinFunction round
syn keyword glslBuiltinFunction roundEven syn keyword glslBuiltinFunction roundEven
syn keyword glslBuiltinFunction shadow1D syn keyword glslBuiltinFunction shadow1D
@@ -598,6 +668,7 @@ syn keyword glslBuiltinFunction sqrt
syn keyword glslBuiltinFunction step syn keyword glslBuiltinFunction step
syn keyword glslBuiltinFunction tan syn keyword glslBuiltinFunction tan
syn keyword glslBuiltinFunction tanh syn keyword glslBuiltinFunction tanh
syn keyword glslBuiltinFunction terminateRayEXT
syn keyword glslBuiltinFunction texelFetch syn keyword glslBuiltinFunction texelFetch
syn keyword glslBuiltinFunction texelFetchOffset syn keyword glslBuiltinFunction texelFetchOffset
syn keyword glslBuiltinFunction texture syn keyword glslBuiltinFunction texture
@@ -632,6 +703,7 @@ syn keyword glslBuiltinFunction textureProjOffset
syn keyword glslBuiltinFunction textureQueryLevels syn keyword glslBuiltinFunction textureQueryLevels
syn keyword glslBuiltinFunction textureQueryLod syn keyword glslBuiltinFunction textureQueryLod
syn keyword glslBuiltinFunction textureSize syn keyword glslBuiltinFunction textureSize
syn keyword glslBuiltinFunction traceRayEXT
syn keyword glslBuiltinFunction transpose syn keyword glslBuiltinFunction transpose
syn keyword glslBuiltinFunction trunc syn keyword glslBuiltinFunction trunc
syn keyword glslBuiltinFunction uaddCarry syn keyword glslBuiltinFunction uaddCarry

View File

@@ -38,7 +38,7 @@ hi def link goLabel Label
hi def link goRepeat Repeat hi def link goRepeat Repeat
" Predefined types " Predefined types
syn keyword goType chan map bool string error syn keyword goType chan map bool string error any comparable
syn keyword goSignedInts int int8 int16 int32 int64 rune syn keyword goSignedInts int int8 int16 int32 int64 rune
syn keyword goUnsignedInts byte uint uint8 uint16 uint32 uint64 uintptr syn keyword goUnsignedInts byte uint uint8 uint16 uint32 uint64 uintptr
syn keyword goFloats float32 float64 syn keyword goFloats float32 float64

View File

@@ -44,7 +44,7 @@ let s:julia_highlight_operators = get(g:, "julia_highlight_operators", 1)
" because those may or may not be valid in the lookbehind on a case-by-case " because those may or may not be valid in the lookbehind on a case-by-case
" basis. " basis.
let s:nonid_chars = '\U00-\U08' . '\U0A-\U1F' let s:nonid_chars = '\U00-\U08' . '\U0A-\U1F'
\ . '\U21-\U28' . '\U2A-\U2F' . '\U3A-\U40' . '\U5B-\U5E' . '\U60' . '\U7B\U7C' \ . '\U21-\U28' . '\U2A-\U2F' . '\U3A-\U40' . '\U5B\U5C\U5E' . '\U60' . '\U7B\U7C'
\ . '\U7E-\UA1' . '\UA7\UA8' . '\UAB-\UAD' . '\UAF\UB1\UB4' . '\UB6-\UB8' . '\UBB\UBF' . '\UD7\UF7' \ . '\U7E-\UA1' . '\UA7\UA8' . '\UAB-\UAD' . '\UAF\UB1\UB4' . '\UB6-\UB8' . '\UBB\UBF' . '\UD7\UF7'
" The complete list " The complete list

View File

@@ -11,7 +11,7 @@ endif
" Read the HTML syntax to start with " Read the HTML syntax to start with
if version < 600 if v:version < 600
so <sfile>:p:h/html.vim so <sfile>:p:h/html.vim
else else
runtime! syntax/html.vim runtime! syntax/html.vim
@@ -21,14 +21,14 @@ else
endif endif
endif endif
if version < 600 if v:version < 600
syntax clear syntax clear
elseif exists("b:current_syntax") elseif exists('b:current_syntax')
finish finish
endif endif
" don't use standard HiLink, it will not work with included syntax files " don't use standard HiLink, it will not work with included syntax files
if version < 508 if v:version < 508
command! -nargs=+ HtmlHiLink hi link <args> command! -nargs=+ HtmlHiLink hi link <args>
else else
command! -nargs=+ HtmlHiLink hi def link <args> command! -nargs=+ HtmlHiLink hi def link <args>
@@ -182,7 +182,7 @@ HtmlHiLink mkdLinkDefTarget mkdURL
HtmlHiLink mkdLinkTitle htmlString HtmlHiLink mkdLinkTitle htmlString
HtmlHiLink mkdDelimiter Delimiter HtmlHiLink mkdDelimiter Delimiter
let b:current_syntax = "mkd" let b:current_syntax = 'mkd'
delcommand HtmlHiLink delcommand HtmlHiLink
" vim: ts=8 " vim: ts=8

View File

@@ -4,7 +4,7 @@ endif
setlocal iskeyword+=- setlocal iskeyword+=-
syntax keyword mermaidDiagramType classDiagram classDiagram-v2 erDiagram gantt graph flowchart pie sequenceDiagram stateDiagram stateDiagram-v2 syntax keyword mermaidDiagramType classDiagram classDiagram-v2 erDiagram gantt graph flowchart pie sequenceDiagram stateDiagram stateDiagram-v2 gitGraph
syntax match mermaidOperator /\v(-|\<|\>|\+|\||\=)/ syntax match mermaidOperator /\v(-|\<|\>|\+|\||\=)/
syntax match mermaidComment /\v^(\s?)+\%\%.*$/ syntax match mermaidComment /\v^(\s?)+\%\%.*$/
syntax region mermaidString start=/"/ end=/"/ skip=/\\"/ syntax region mermaidString start=/"/ end=/"/ skip=/\\"/
@@ -35,6 +35,9 @@ syntax match mermaidClassFunction /\v\w+\(((\w+|\s+|\~)?,?)+\)/ contains=ALLBUT,
syntax match mermaidStateFinalKeyword /\[\*\]/ syntax match mermaidStateFinalKeyword /\[\*\]/
syntax match mermaidStateKeyword /\v(\s+as[^a-z]|^\s+state)/ syntax match mermaidStateKeyword /\v(\s+as[^a-z]|^\s+state)/
syntax match mermaidGitOption /\v^(options|end)/
syntax match mermaidGitCommands /\v^(commit|branch|merge|reset|checkout)/
" TODO highlight gantt keywords " TODO highlight gantt keywords
" TODO improve er operators " TODO improve er operators
@@ -63,3 +66,6 @@ highlight link mermaidStateFinalKeyword Keyword
highlight link mermaidStateKeyword Keyword highlight link mermaidStateKeyword Keyword
highlight link mermaidErOperator Operator highlight link mermaidErOperator Operator
highlight link mermaidGitOption Keyword
highlight link mermaidGitCommands Keyword

View File

@@ -34,6 +34,9 @@ syntax keyword odinTypeIdOf typeid_of
syntax keyword odinTypeOf type_of syntax keyword odinTypeOf type_of
syntax keyword odinAlignOf align_of syntax keyword odinAlignOf align_of
syntax keyword odinOrReturn or_return
syntax keyword odinOrElse or_else
syntax keyword odinInline inline syntax keyword odinInline inline
syntax keyword odinNoInline no_inline syntax keyword odinNoInline no_inline
@@ -116,6 +119,8 @@ highlight link odinTypeInfoOf Keyword
highlight link odinTypeIdOf Keyword highlight link odinTypeIdOf Keyword
highlight link odinAlignOf Keyword highlight link odinAlignOf Keyword
highlight link odinPackage Keyword highlight link odinPackage Keyword
highlight link odinOrReturn Keyword
highlight link odinOrElse Keyword
highlight link odinInline Keyword highlight link odinInline Keyword
highlight link odinNoInline Keyword highlight link odinNoInline Keyword

View File

@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'ocaml', 'syntax/opam.vim')
endif endif
" Vim syntax file " Vim syntax file
" Language: OPAM - OCaml package manager " Language: opam - OCaml package manager
" Maintainer: Markus Mottl <markus.mottl@gmail.com> " Maintainer: Markus Mottl <markus.mottl@gmail.com>
" URL: https://github.com/ocaml/vim-ocaml " URL: https://github.com/ocaml/vim-ocaml
" Last Change: " Last Change:
@@ -15,8 +15,36 @@ endif
" need %{vars}% " need %{vars}%
" env: [[CAML_LD_LIBRARY_PATH = "%{lib}%/stublibs"]] " env: [[CAML_LD_LIBRARY_PATH = "%{lib}%/stublibs"]]
syn keyword opamKeyword1 remove depends pin-depends depopts conflicts env packages patches version maintainer tags license homepage authors doc install author available name depexts substs synopsis description syn keyword opamKeyword1 author
syn match opamKeyword2 "\v(bug-reports|post-messages|ocaml-version|opam-version|dev-repo|build-test|build-doc|build)" syn keyword opamKeyword1 authors
syn keyword opamKeyword1 available
syn keyword opamKeyword1 conflicts
syn keyword opamKeyword1 depends
syn keyword opamKeyword1 depexts
syn keyword opamKeyword1 depopts
syn keyword opamKeyword1 description
syn keyword opamKeyword1 doc
syn keyword opamKeyword1 extra-files
syn keyword opamKeyword1 features
syn keyword opamKeyword1 flags
syn keyword opamKeyword1 homepage
syn keyword opamKeyword1 install
syn keyword opamKeyword1 libraries
syn keyword opamKeyword1 license
syn keyword opamKeyword1 maintainer
syn keyword opamKeyword1 messages
syn keyword opamKeyword1 name
syn keyword opamKeyword1 patches
syn keyword opamKeyword1 pin-depends
syn keyword opamKeyword1 remove
syn keyword opamKeyword1 run-test
syn keyword opamKeyword1 setenv
syn keyword opamKeyword1 substs
syn keyword opamKeyword1 synopsis
syn keyword opamKeyword1 syntax
syn keyword opamKeyword1 tags
syn keyword opamKeyword1 version
syn match opamKeyword2 "\v(bug-reports|post-messages|opam-version|dev-repo|build)"
syn keyword opamTodo FIXME NOTE NOTES TODO XXX contained syn keyword opamTodo FIXME NOTE NOTES TODO XXX contained
syn match opamComment "#.*$" contains=opamTodo,@Spell syn match opamComment "#.*$" contains=opamTodo,@Spell

View File

@@ -5,10 +5,9 @@ endif
scriptencoding utf-8 scriptencoding utf-8
" Vim syntax file " Vim syntax file
" Language: PlantUML " Language: PlantUML
" Maintainer: Anders Thøgersen <first name at bladre dot dk>
" License: VIM LICENSE " License: VIM LICENSE
if exists('b:current_syntax') if exists('b:current_syntax')
" finish finish
endif endif
if v:version < 600 if v:version < 600
@@ -22,14 +21,16 @@ let b:current_syntax = 'plantuml'
syntax sync minlines=100 syntax sync minlines=100
syntax match plantumlPreProc /\%(\%(^@start\|^@end\)\%(dot\|mindmap\|uml\|salt\|wbs\|gantt\)\)\|!\%(define\|definelong\|else\|enddefinelong\|endif\|exit\|if\|ifdef\|ifndef\|include\|pragma\|undef\|gantt\)\s*.*/ contains=plantumlDir syntax match plantumlPreProc /\%(^@start\|^@end\)\%(board\|bpm\|creole\|cute\|def\|ditaa\|dot\|flow\|gantt\|git\|jcckit\|json\|latex\|math\|mindmap\|nwdiag\|project\|salt\|tree\|uml\|wbs\|wire\|yaml\)/
syntax match plantumlPreProc /!\%(assert\|define\|definelong\|dump_memory\|else\|enddefinelong\|endfunction\|endif\|endprocedure\|endsub\|exit\|function\|if\|ifdef\|ifndef\|import\|include\|local\|log\|pragma\|procedure\|return\|startsub\|theme\|undef\|unquoted\)\s*.*/ contains=plantumlDir
syntax region plantumlDir start=/\s\+/ms=s+1 end=/$/ contained syntax region plantumlDir start=/\s\+/ms=s+1 end=/$/ contained
" type " type
" From 'java - jar plantuml.jar - language' results {{{ " From 'java - jar plantuml.jar - language' results {{{
syntax keyword plantumlTypeKeyword abstract actor agent archimate artifact boundary card cloud component control syntax keyword plantumlTypeKeyword abstract actor agent annotation archimate artifact boundary card cloud
syntax keyword plantumlTypeKeyword database detach diamond entity enum file folder frame node object package syntax keyword plantumlTypeKeyword collections component control database diamond entity enum file folder frame
syntax keyword plantumlTypeKeyword participant queue rectangle stack state storage usecase syntax keyword plantumlTypeKeyword hexagon label node object package participant person queue rectangle stack state
syntax keyword plantumlTypeKeyword storage usecase
" class and interface are defined as plantumlClassKeyword " class and interface are defined as plantumlClassKeyword
syntax keyword plantumlClassKeyword class interface syntax keyword plantumlClassKeyword class interface
"}}} "}}}
@@ -38,13 +39,16 @@ syntax keyword plantumlTypeKeyword concise robust
" keyword " keyword
" From 'java - jar plantuml.jar - language' results {{{ " From 'java - jar plantuml.jar - language' results {{{
" Since "syntax keyword" can handle only words, "top to bottom direction" is excluded. " Since "syntax keyword" can handle only words, "top to bottom direction", "left to right direction" are excluded.
syntax keyword plantumlKeyword accross activate again allow_mixing allowmixing also alt as autonumber bottom syntax keyword plantumlKeyword across activate again allow_mixing allowmixing also alt as autonumber bold
syntax keyword plantumlKeyword box break caption center create critical deactivate destroy down else elseif end syntax keyword plantumlKeyword bottom box break caption center circle color create critical dashed deactivate
syntax keyword plantumlKeyword endif endwhile footbox footer fork group header hide hnote if is kill left syntax keyword plantumlKeyword description destroy detach dotted down else elseif empty end endif endwhile
syntax keyword plantumlKeyword legend link loop mainframe namespace newpage note of on opt order over package syntax keyword plantumlKeyword false footbox footer fork group header hide hnote if is italic kill left legend
syntax keyword plantumlKeyword page par partition ref repeat return right rnote rotate show skin skinparam syntax keyword plantumlKeyword link loop mainframe map members namespace newpage normal note of on opt order
syntax keyword plantumlKeyword split start stereotype stop title top up while syntax keyword plantumlKeyword over package page par partition plain ref repeat return right rnote rotate show
syntax keyword plantumlKeyword skin skinparam split sprite start stereotype stop style then title top true up
syntax keyword plantumlKeyword while
"}}} "}}}
" Not in 'java - jar plantuml.jar - language' results " Not in 'java - jar plantuml.jar - language' results
syntax keyword plantumlKeyword endlegend sprite then syntax keyword plantumlKeyword endlegend sprite then
@@ -122,8 +126,8 @@ syntax cluster plantumlClassOp contains=plantumlClassPublic,
" Strings " Strings
syntax match plantumlSpecialString /\\n/ contained syntax match plantumlSpecialString /\\n/ contained
syntax region plantumlString start=/"/ skip=/\\\\\|\\"/ end=/"/ contains=plantumlSpecialString syntax region plantumlString start=/"/ skip=/\\\\\|\\"/ end=/"/ contains=plantumlSpecialString
syntax region plantumlString start=/'/ skip=/\\\\\|\\'/ end=/'/ contains=plantumlSpecialString syntax region plantumlString start=/'/ skip=/\\\\\|\\'/ end=/'/ oneline contains=plantumlSpecialString
syntax match plantumlComment /'.*$/ contains=plantumlCommentTODO syntax match plantumlComment /^\s*'.*$/ contains=plantumlCommentTODO
syntax region plantumlMultilineComment start=/\/'/ end=/'\// contains=plantumlCommentTODO syntax region plantumlMultilineComment start=/\/'/ end=/'\// contains=plantumlCommentTODO
syntax match plantumlTag /<\/\?[bi]>/ syntax match plantumlTag /<\/\?[bi]>/
@@ -177,6 +181,9 @@ execute 'syntax region plantumlMindmap start=/^\([-+*]\)\1*' . s:mindmap_options
" Markdown syntax " Markdown syntax
execute 'syntax region plantumlMindmap oneline start=/^\s*\*' . s:mindmap_options . '\s/ end=/$/ contains=' . join(s:contained, ',') execute 'syntax region plantumlMindmap oneline start=/^\s*\*' . s:mindmap_options . '\s/ end=/$/ contains=' . join(s:contained, ',')
" Gantt diagram
syntax match plantumlGanttTask /\[[^\]]\{-}\]\%('s\)\?/ contains=plantumlSpecialString
" Skinparam keywords " Skinparam keywords
syntax case ignore syntax case ignore
@@ -195,10 +202,10 @@ syntax keyword plantumlSkinparamKeyword ArchimateBackgroundColor ArchimateBorder
syntax keyword plantumlSkinparamKeyword ArchimateFontColor ArchimateFontName ArchimateFontSize ArchimateFontStyle syntax keyword plantumlSkinparamKeyword ArchimateFontColor ArchimateFontName ArchimateFontSize ArchimateFontStyle
syntax keyword plantumlSkinparamKeyword ArchimateStereotypeFontColor ArchimateStereotypeFontName syntax keyword plantumlSkinparamKeyword ArchimateStereotypeFontColor ArchimateStereotypeFontName
syntax keyword plantumlSkinparamKeyword ArchimateStereotypeFontSize ArchimateStereotypeFontStyle ArrowColor syntax keyword plantumlSkinparamKeyword ArchimateStereotypeFontSize ArchimateStereotypeFontStyle ArrowColor
syntax keyword plantumlSkinparamKeyword ArrowFontColor ArrowFontName ArrowFontSize ArrowFontStyle ArrowLollipopColor syntax keyword plantumlSkinparamKeyword ArrowFontColor ArrowFontName ArrowFontSize ArrowFontStyle ArrowHeadColor
syntax keyword plantumlSkinparamKeyword ArrowMessageAlignment ArrowThickness ArtifactBackgroundColor ArtifactBorderColor syntax keyword plantumlSkinparamKeyword ArrowLollipopColor ArrowMessageAlignment ArrowThickness ArtifactBackgroundColor
syntax keyword plantumlSkinparamKeyword ArtifactFontColor ArtifactFontName ArtifactFontSize ArtifactFontStyle syntax keyword plantumlSkinparamKeyword ArtifactBorderColor ArtifactFontColor ArtifactFontName ArtifactFontSize
syntax keyword plantumlSkinparamKeyword ArtifactStereotypeFontColor ArtifactStereotypeFontName syntax keyword plantumlSkinparamKeyword ArtifactFontStyle ArtifactStereotypeFontColor ArtifactStereotypeFontName
syntax keyword plantumlSkinparamKeyword ArtifactStereotypeFontSize ArtifactStereotypeFontStyle BackgroundColor syntax keyword plantumlSkinparamKeyword ArtifactStereotypeFontSize ArtifactStereotypeFontStyle BackgroundColor
syntax keyword plantumlSkinparamKeyword BiddableBackgroundColor BiddableBorderColor BoundaryBackgroundColor syntax keyword plantumlSkinparamKeyword BiddableBackgroundColor BiddableBorderColor BoundaryBackgroundColor
syntax keyword plantumlSkinparamKeyword BoundaryBorderColor BoundaryFontColor BoundaryFontName BoundaryFontSize syntax keyword plantumlSkinparamKeyword BoundaryBorderColor BoundaryFontColor BoundaryFontName BoundaryFontSize
@@ -252,42 +259,50 @@ syntax keyword plantumlSkinparamKeyword FooterFontStyle FrameBackgroundColor Fra
syntax keyword plantumlSkinparamKeyword FrameFontName FrameFontSize FrameFontStyle FrameStereotypeFontColor syntax keyword plantumlSkinparamKeyword FrameFontName FrameFontSize FrameFontStyle FrameStereotypeFontColor
syntax keyword plantumlSkinparamKeyword FrameStereotypeFontName FrameStereotypeFontSize FrameStereotypeFontStyle syntax keyword plantumlSkinparamKeyword FrameStereotypeFontName FrameStereotypeFontSize FrameStereotypeFontStyle
syntax keyword plantumlSkinparamKeyword GenericDisplay Guillemet Handwritten HeaderFontColor HeaderFontName syntax keyword plantumlSkinparamKeyword GenericDisplay Guillemet Handwritten HeaderFontColor HeaderFontName
syntax keyword plantumlSkinparamKeyword HeaderFontSize HeaderFontStyle HyperlinkColor HyperlinkUnderline syntax keyword plantumlSkinparamKeyword HeaderFontSize HeaderFontStyle HexagonBackgroundColor HexagonBorderColor
syntax keyword plantumlSkinparamKeyword IconIEMandatoryColor IconPackageBackgroundColor IconPackageColor syntax keyword plantumlSkinparamKeyword HexagonBorderThickness HexagonFontColor HexagonFontName HexagonFontSize
syntax keyword plantumlSkinparamKeyword IconPrivateBackgroundColor IconPrivateColor IconProtectedBackgroundColor syntax keyword plantumlSkinparamKeyword HexagonFontStyle HexagonStereotypeFontColor HexagonStereotypeFontName
syntax keyword plantumlSkinparamKeyword IconProtectedColor IconPublicBackgroundColor IconPublicColor syntax keyword plantumlSkinparamKeyword HexagonStereotypeFontSize HexagonStereotypeFontStyle HyperlinkColor
syntax keyword plantumlSkinparamKeyword InterfaceBackgroundColor InterfaceBorderColor InterfaceFontColor syntax keyword plantumlSkinparamKeyword HyperlinkUnderline IconIEMandatoryColor IconPackageBackgroundColor
syntax keyword plantumlSkinparamKeyword IconPackageColor IconPrivateBackgroundColor IconPrivateColor
syntax keyword plantumlSkinparamKeyword IconProtectedBackgroundColor IconProtectedColor IconPublicBackgroundColor
syntax keyword plantumlSkinparamKeyword IconPublicColor InterfaceBackgroundColor InterfaceBorderColor InterfaceFontColor
syntax keyword plantumlSkinparamKeyword InterfaceFontName InterfaceFontSize InterfaceFontStyle syntax keyword plantumlSkinparamKeyword InterfaceFontName InterfaceFontSize InterfaceFontStyle
syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontColor InterfaceStereotypeFontName syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontColor InterfaceStereotypeFontName
syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontSize InterfaceStereotypeFontStyle LegendBackgroundColor syntax keyword plantumlSkinparamKeyword InterfaceStereotypeFontSize InterfaceStereotypeFontStyle LabelFontColor
syntax keyword plantumlSkinparamKeyword LegendBorderColor LegendBorderThickness LegendFontColor LegendFontName syntax keyword plantumlSkinparamKeyword LabelFontName LabelFontSize LabelFontStyle LabelStereotypeFontColor
syntax keyword plantumlSkinparamKeyword LegendFontSize LegendFontStyle LexicalBackgroundColor LexicalBorderColor syntax keyword plantumlSkinparamKeyword LabelStereotypeFontName LabelStereotypeFontSize LabelStereotypeFontStyle
syntax keyword plantumlSkinparamKeyword LifelineStrategy Linetype MachineBackgroundColor MachineBorderColor syntax keyword plantumlSkinparamKeyword LegendBackgroundColor LegendBorderColor LegendBorderThickness LegendFontColor
syntax keyword plantumlSkinparamKeyword LineColor LineStyle LineThickness syntax keyword plantumlSkinparamKeyword LegendFontName LegendFontSize LegendFontStyle LexicalBackgroundColor
syntax keyword plantumlSkinparamKeyword MachineBorderThickness MachineFontColor MachineFontName MachineFontSize syntax keyword plantumlSkinparamKeyword LexicalBorderColor LifelineStrategy Linetype MachineBackgroundColor
syntax keyword plantumlSkinparamKeyword MachineFontStyle MachineStereotypeFontColor MachineStereotypeFontName syntax keyword plantumlSkinparamKeyword MachineBorderColor MachineBorderThickness MachineFontColor MachineFontName
syntax keyword plantumlSkinparamKeyword MachineStereotypeFontSize MachineStereotypeFontStyle MaxAsciiMessageLength syntax keyword plantumlSkinparamKeyword MachineFontSize MachineFontStyle MachineStereotypeFontColor
syntax keyword plantumlSkinparamKeyword MaxMessageSize MinClassWidth Monochrome NodeBackgroundColor NodeBorderColor syntax keyword plantumlSkinparamKeyword MachineStereotypeFontName MachineStereotypeFontSize MachineStereotypeFontStyle
syntax keyword plantumlSkinparamKeyword NodeFontColor NodeFontName NodeFontSize NodeFontStyle NodeStereotypeFontColor syntax keyword plantumlSkinparamKeyword MaxAsciiMessageLength MaxMessageSize MinClassWidth Monochrome
syntax keyword plantumlSkinparamKeyword NodeStereotypeFontName NodeStereotypeFontSize NodeStereotypeFontStyle Nodesep syntax keyword plantumlSkinparamKeyword NodeBackgroundColor NodeBorderColor NodeFontColor NodeFontName NodeFontSize
syntax keyword plantumlSkinparamKeyword NoteBackgroundColor NoteBorderColor NoteBorderThickness NoteFontColor syntax keyword plantumlSkinparamKeyword NodeFontStyle NodeStereotypeFontColor NodeStereotypeFontName
syntax keyword plantumlSkinparamKeyword NoteFontName NoteFontSize NoteFontStyle NoteShadowing NoteTextAlignment syntax keyword plantumlSkinparamKeyword NodeStereotypeFontSize NodeStereotypeFontStyle Nodesep NoteBackgroundColor
syntax keyword plantumlSkinparamKeyword ObjectAttributeFontColor ObjectAttributeFontName ObjectAttributeFontSize syntax keyword plantumlSkinparamKeyword NoteBorderColor NoteBorderThickness NoteFontColor NoteFontName NoteFontSize
syntax keyword plantumlSkinparamKeyword ObjectAttributeFontStyle ObjectBackgroundColor ObjectBorderColor syntax keyword plantumlSkinparamKeyword NoteFontStyle NoteShadowing NoteTextAlignment ObjectAttributeFontColor
syntax keyword plantumlSkinparamKeyword ObjectBorderThickness ObjectFontColor ObjectFontName ObjectFontSize syntax keyword plantumlSkinparamKeyword ObjectAttributeFontName ObjectAttributeFontSize ObjectAttributeFontStyle
syntax keyword plantumlSkinparamKeyword ObjectFontStyle ObjectStereotypeFontColor ObjectStereotypeFontName syntax keyword plantumlSkinparamKeyword ObjectBackgroundColor ObjectBorderColor ObjectBorderThickness ObjectFontColor
syntax keyword plantumlSkinparamKeyword ObjectStereotypeFontSize ObjectStereotypeFontStyle PackageBackgroundColor syntax keyword plantumlSkinparamKeyword ObjectFontName ObjectFontSize ObjectFontStyle ObjectStereotypeFontColor
syntax keyword plantumlSkinparamKeyword PackageBorderColor PackageBorderThickness PackageFontColor PackageFontName syntax keyword plantumlSkinparamKeyword ObjectStereotypeFontName ObjectStereotypeFontSize ObjectStereotypeFontStyle
syntax keyword plantumlSkinparamKeyword PackageFontSize PackageFontStyle PackageStereotypeFontColor syntax keyword plantumlSkinparamKeyword PackageBackgroundColor PackageBorderColor PackageBorderThickness
syntax keyword plantumlSkinparamKeyword PackageStereotypeFontName PackageStereotypeFontSize PackageStereotypeFontStyle syntax keyword plantumlSkinparamKeyword PackageFontColor PackageFontName PackageFontSize PackageFontStyle
syntax keyword plantumlSkinparamKeyword PackageStyle PackageTitleAlignment Padding PageBorderColor PageExternalColor syntax keyword plantumlSkinparamKeyword PackageStereotypeFontColor PackageStereotypeFontName PackageStereotypeFontSize
syntax keyword plantumlSkinparamKeyword PageMargin ParticipantBackgroundColor ParticipantBorderColor syntax keyword plantumlSkinparamKeyword PackageStereotypeFontStyle PackageStyle PackageTitleAlignment Padding
syntax keyword plantumlSkinparamKeyword ParticipantFontColor ParticipantFontName ParticipantFontSize syntax keyword plantumlSkinparamKeyword PageBorderColor PageExternalColor PageMargin ParticipantBackgroundColor
syntax keyword plantumlSkinparamKeyword ParticipantFontStyle ParticipantPadding ParticipantStereotypeFontColor syntax keyword plantumlSkinparamKeyword ParticipantBorderColor ParticipantFontColor ParticipantFontName
syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontName ParticipantStereotypeFontSize syntax keyword plantumlSkinparamKeyword ParticipantFontSize ParticipantFontStyle ParticipantPadding
syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontStyle PartitionBackgroundColor PartitionBorderColor syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontColor ParticipantStereotypeFontName
syntax keyword plantumlSkinparamKeyword PartitionBorderThickness PartitionFontColor PartitionFontName PartitionFontSize syntax keyword plantumlSkinparamKeyword ParticipantStereotypeFontSize ParticipantStereotypeFontStyle
syntax keyword plantumlSkinparamKeyword PartitionFontStyle PathHoverColor QueueBackgroundColor QueueBorderColor syntax keyword plantumlSkinparamKeyword PartitionBackgroundColor PartitionBorderColor PartitionBorderThickness
syntax keyword plantumlSkinparamKeyword PartitionFontColor PartitionFontName PartitionFontSize PartitionFontStyle
syntax keyword plantumlSkinparamKeyword PathHoverColor PersonBackgroundColor PersonBorderColor PersonBorderThickness
syntax keyword plantumlSkinparamKeyword PersonFontColor PersonFontName PersonFontSize PersonFontStyle
syntax keyword plantumlSkinparamKeyword PersonStereotypeFontColor PersonStereotypeFontName PersonStereotypeFontSize
syntax keyword plantumlSkinparamKeyword PersonStereotypeFontStyle QueueBackgroundColor QueueBorderColor
syntax keyword plantumlSkinparamKeyword QueueBorderThickness QueueFontColor QueueFontName QueueFontSize QueueFontStyle syntax keyword plantumlSkinparamKeyword QueueBorderThickness QueueFontColor QueueFontName QueueFontSize QueueFontStyle
syntax keyword plantumlSkinparamKeyword QueueStereotypeFontColor QueueStereotypeFontName QueueStereotypeFontSize syntax keyword plantumlSkinparamKeyword QueueStereotypeFontColor QueueStereotypeFontName QueueStereotypeFontSize
syntax keyword plantumlSkinparamKeyword QueueStereotypeFontStyle Ranksep RectangleBackgroundColor RectangleBorderColor syntax keyword plantumlSkinparamKeyword QueueStereotypeFontStyle Ranksep RectangleBackgroundColor RectangleBorderColor
@@ -343,6 +358,7 @@ syntax keyword plantumlSkinparamKeyword UsecaseBackgroundColor UsecaseBorderColo
syntax keyword plantumlSkinparamKeyword UsecaseFontColor UsecaseFontName UsecaseFontSize UsecaseFontStyle syntax keyword plantumlSkinparamKeyword UsecaseFontColor UsecaseFontName UsecaseFontSize UsecaseFontStyle
syntax keyword plantumlSkinparamKeyword UsecaseStereotypeFontColor UsecaseStereotypeFontName UsecaseStereotypeFontSize syntax keyword plantumlSkinparamKeyword UsecaseStereotypeFontColor UsecaseStereotypeFontName UsecaseStereotypeFontSize
syntax keyword plantumlSkinparamKeyword UsecaseStereotypeFontStyle WrapWidth syntax keyword plantumlSkinparamKeyword UsecaseStereotypeFontStyle WrapWidth
" Not in 'java - jar plantuml.jar - language' output " Not in 'java - jar plantuml.jar - language' output
syntax keyword plantumlSkinparamKeyword activityArrowColor activityArrowFontColor activityArrowFontName syntax keyword plantumlSkinparamKeyword activityArrowColor activityArrowFontColor activityArrowFontName
syntax keyword plantumlSkinparamKeyword activityArrowFontSize activityArrowFontStyle BarColor BorderColor syntax keyword plantumlSkinparamKeyword activityArrowFontSize activityArrowFontStyle BarColor BorderColor
@@ -357,6 +373,7 @@ syntax keyword plantumlSkinparamKeyword FontSize FontStyle GroupBackgroundColor
syntax keyword plantumlSkinparamKeyword GroupingFontSize GroupingFontStyle GroupingHeaderFontColor syntax keyword plantumlSkinparamKeyword GroupingFontSize GroupingFontStyle GroupingHeaderFontColor
syntax keyword plantumlSkinparamKeyword GroupingHeaderFontName GroupingHeaderFontSize GroupingHeaderFontStyle syntax keyword plantumlSkinparamKeyword GroupingHeaderFontName GroupingHeaderFontSize GroupingHeaderFontStyle
syntax keyword plantumlSkinparamKeyword LifeLineBackgroundColor LifeLineBorderColor syntax keyword plantumlSkinparamKeyword LifeLineBackgroundColor LifeLineBorderColor
syntax keyword plantumlSkinparamKeyword LineColor LineStyle LineThickness
syntax keyword plantumlSkinparamKeyword sequenceActorBackgroundColor sequenceActorBorderColor sequenceActorFontColor syntax keyword plantumlSkinparamKeyword sequenceActorBackgroundColor sequenceActorBorderColor sequenceActorFontColor
syntax keyword plantumlSkinparamKeyword sequenceActorFontName sequenceActorFontSize sequenceActorFontStyle syntax keyword plantumlSkinparamKeyword sequenceActorFontName sequenceActorFontSize sequenceActorFontStyle
syntax keyword plantumlSkinparamKeyword sequenceArrowColor sequenceArrowFontColor sequenceArrowFontName syntax keyword plantumlSkinparamKeyword sequenceArrowColor sequenceArrowFontColor sequenceArrowFontName
@@ -377,6 +394,10 @@ syntax keyword plantumlSkinparamKeyword usecaseActorStereotypeFontStyle usecaseA
syntax keyword plantumlSkinparamKeyword usecaseArrowFontName usecaseArrowFontSize usecaseArrowFontStyle syntax keyword plantumlSkinparamKeyword usecaseArrowFontName usecaseArrowFontSize usecaseArrowFontStyle
syntax case match syntax case match
" Builtin Function
" https://plantuml.com/ja/preprocessing
syntax match plantumlBuiltinFunction /%\%(chr\|darken\|date\|dec2hex\|dirpath\|feature\|false\|file_exists\|filename\|function_exists\|get_variable_value\|getenv\|hex2dec\|hsl_color\|intval\|is_dark\|is_light\|lighten\|loadJSON\|lower\|newline\|not\|lighten\|reverse_color\|reverse_hsluv_color\|set_variable_value\|size\|string\|strlen\|strpos\|substr\|true\|upper\|variable_exists\|version\)/
" Highlight " Highlight
highlight default link plantumlCommentTODO Todo highlight default link plantumlCommentTODO Todo
highlight default link plantumlKeyword Keyword highlight default link plantumlKeyword Keyword
@@ -415,6 +436,8 @@ highlight default link plantumlSkinparamKeyword Identifier
highlight default link plantumlNoteMultiLine String highlight default link plantumlNoteMultiLine String
highlight default link plantumlUsecaseActor String highlight default link plantumlUsecaseActor String
highlight default link plantumlStereotype Type highlight default link plantumlStereotype Type
highlight default link plantumlBuiltinFunction Function
highlight default link plantumlGanttTask Type
let &cpoptions=s:cpo_orig let &cpoptions=s:cpo_orig
unlet s:cpo_orig unlet s:cpo_orig

View File

@@ -5,7 +5,7 @@ endif
" Vim syntax file " Vim syntax file
" Language: M$ Resource files (*.rc) " Language: M$ Resource files (*.rc)
" Maintainer: Christian Brabandt " Maintainer: Christian Brabandt
" Last Change: 2015-05-29 " Last Change: 20220116
" Repository: https://github.com/chrisbra/vim-rc-syntax " Repository: https://github.com/chrisbra/vim-rc-syntax
" License: Vim (see :h license) " License: Vim (see :h license)
" Previous Maintainer: Heiko Erhardt <Heiko.Erhardt@munich.netsurf.de> " Previous Maintainer: Heiko Erhardt <Heiko.Erhardt@munich.netsurf.de>
@@ -177,18 +177,19 @@ hi def link rcAttribute rcCommonAttribute
hi def link rcStdId rcStatement hi def link rcStdId rcStatement
hi def link rcStatement Statement hi def link rcStatement Statement
" Default color overrides hi def link rcLanguage Constant
hi def rcLanguage term=reverse ctermbg=Red ctermfg=Yellow guibg=Red guifg=Yellow hi def link rcCaptionParam Constant
hi def rcMainObject term=underline ctermfg=Blue guifg=Blue hi def link rcCommonAttribute Constant
hi def rcSubObject ctermfg=Green guifg=Green
hi def rcCaptionParam term=underline ctermfg=DarkGreen guifg=Green
hi def rcParam ctermfg=DarkGreen guifg=DarkGreen
hi def rcStatement ctermfg=DarkGreen guifg=DarkGreen
hi def rcCommonAttribute ctermfg=Brown guifg=Brown
hi def link rcMainObject Identifier
hi def link rcSubObject Define
hi def link rcParam Constant
hi def link rcStatement Statement
"
"hi def link rcIdentifier Identifier "hi def link rcIdentifier Identifier
let b:current_syntax = "rc" let b:current_syntax = "rc"
" vim: ts=8 " vim: ts=8

View File

@@ -215,6 +215,7 @@ syntax keyword swiftAttributes
\ @NSCopying \ @NSCopying
\ @NSManaged \ @NSManaged
\ @objc \ @objc
\ @preconcurrency
\ @propertyWrapper \ @propertyWrapper
\ @resultBuilder \ @resultBuilder
\ @Sendable \ @Sendable
@@ -223,7 +224,9 @@ syntax keyword swiftAttributes
\ @usableFromInline \ @usableFromInline
\ @warn_unused_result \ @warn_unused_result
syntax keyword swiftConditionStatement #available syntax keyword swiftConditionStatement
\ #available
\ #unavailable
syntax keyword swiftStructure syntax keyword swiftStructure
\ struct \ struct

View File

@@ -3,7 +3,7 @@ if polyglot#init#is_disabled(expand('<sfile>:p'), 'tmux', 'syntax/tmux.vim')
endif endif
" Language: tmux(1) configuration file " Language: tmux(1) configuration file
" Version: 3.3-rc (git-77fc7ac3) " Version: 3.3-rc (git-85ef7359)
" URL: https://github.com/ericpruitt/tmux.vim/ " URL: https://github.com/ericpruitt/tmux.vim/
" Maintainer: Eric Pruitt <eric.pruitt@gmail.com> " Maintainer: Eric Pruitt <eric.pruitt@gmail.com>
" License: 2-Clause BSD (http://opensource.org/licenses/BSD-2-Clause) " License: 2-Clause BSD (http://opensource.org/licenses/BSD-2-Clause)
@@ -78,23 +78,24 @@ syn keyword tmuxOptions
\ display-panes-active-colour display-panes-colour display-panes-time \ display-panes-active-colour display-panes-colour display-panes-time
\ display-time exit-empty exit-unattached extended-keys focus-events \ display-time exit-empty exit-unattached extended-keys focus-events
\ history-file history-limit key-table lock-after-time lock-command \ history-file history-limit key-table lock-after-time lock-command
\ message-command-style message-limit aggressive-resize allow-rename \ message-command-style message-limit aggressive-resize allow-passthrough
\ alternate-screen automatic-rename automatic-rename-format \ allow-rename alternate-screen automatic-rename automatic-rename-format
\ clock-mode-colour clock-mode-style copy-mode-current-match-style \ clock-mode-colour clock-mode-style copy-mode-current-match-style
\ copy-mode-mark-style copy-mode-match-style main-pane-height \ copy-mode-mark-style copy-mode-match-style main-pane-height
\ main-pane-width message-style mode-keys mode-style monitor-activity \ main-pane-width message-style mode-keys mode-style monitor-activity
\ monitor-bell monitor-silence mouse other-pane-height other-pane-width \ monitor-bell monitor-silence mouse other-pane-height other-pane-width
\ pane-active-border-style pane-base-index pane-border-format \ pane-active-border-style pane-base-index pane-border-format
\ pane-border-lines pane-border-status pane-border-style pane-colours \ pane-border-indicators pane-border-lines pane-border-status
\ popup-border-lines popup-border-style popup-style prefix prefix2 \ pane-border-style pane-colours popup-border-lines popup-border-style
\ prompt-history-limit remain-on-exit renumber-windows repeat-time \ popup-style prefix prefix2 prompt-history-limit remain-on-exit
\ set-clipboard set-titles set-titles-string silence-action status status-bg \ renumber-windows repeat-time set-clipboard set-titles set-titles-string
\ status-fg status-format status-interval status-justify status-keys \ silence-action status status-bg status-fg status-format status-interval
\ status-left status-left-length status-left-style status-position \ status-justify status-keys status-left status-left-length
\ status-right status-right-length status-right-style status-style \ status-left-style status-position status-right status-right-length
\ synchronize-panes terminal-features terminal-overrides update-environment \ status-right-style status-style synchronize-panes terminal-features
\ user-keys visual-activity visual-bell visual-silence window-active-style \ terminal-overrides update-environment user-keys visual-activity
\ window-size window-status-activity-style window-status-bell-style \ visual-bell visual-silence window-active-style window-size
\ window-status-activity-style window-status-bell-style
\ window-status-current-format window-status-current-style \ window-status-current-format window-status-current-style
\ window-status-format window-status-last-style window-status-separator \ window-status-format window-status-last-style window-status-separator
\ window-status-style window-style word-separators wrap-search \ window-status-style window-style word-separators wrap-search

View File

@@ -22,6 +22,7 @@ let s:zig_syntax_keywords = {
\ , "f16" \ , "f16"
\ , "f32" \ , "f32"
\ , "f64" \ , "f64"
\ , "f80"
\ , "f128" \ , "f128"
\ , "void" \ , "void"
\ , "type" \ , "type"
@@ -146,6 +147,7 @@ let s:zig_syntax_keywords = {
\ , "@offsetOf" \ , "@offsetOf"
\ , "@OpaqueType" \ , "@OpaqueType"
\ , "@panic" \ , "@panic"
\ , "@prefetch"
\ , "@ptrCast" \ , "@ptrCast"
\ , "@ptrToInt" \ , "@ptrToInt"
\ , "@rem" \ , "@rem"
@@ -154,6 +156,7 @@ let s:zig_syntax_keywords = {
\ , "@Type" \ , "@Type"
\ , "@shuffle" \ , "@shuffle"
\ , "@reduce" \ , "@reduce"
\ , "@select"
\ , "@setRuntimeSafety" \ , "@setRuntimeSafety"
\ , "@setEvalBranchQuota" \ , "@setEvalBranchQuota"
\ , "@setFloatMode" \ , "@setFloatMode"