mirror of
https://github.com/sheerun/vim-polyglot.git
synced 2025-11-08 19:43:52 -05:00
Compare commits
12 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9fd5c11a20 | ||
|
|
679ccf0303 | ||
|
|
eacf785f5a | ||
|
|
83bd298476 | ||
|
|
415261dd1f | ||
|
|
4d18a5e5dd | ||
|
|
a55b6aa3aa | ||
|
|
1d45a6d4f0 | ||
|
|
420a65e9b0 | ||
|
|
2254b83675 | ||
|
|
12755e3583 | ||
|
|
cbad6b1e0a |
18
.github/ISSUE_TEMPLATE/add-language.md
vendored
Normal file
18
.github/ISSUE_TEMPLATE/add-language.md
vendored
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
---
|
||||||
|
name: Add language
|
||||||
|
about: Add support for new language
|
||||||
|
title: ''
|
||||||
|
labels: ''
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
<!--- vim-polyglot accepts only lightweight, maintained github-hosted vim plugins -->
|
||||||
|
|
||||||
|
**GitHub repository url**
|
||||||
|
|
||||||
|
|
||||||
|
**Is this plugin well maintained?**
|
||||||
|
|
||||||
|
|
||||||
|
**Is this plugin lightweight? (no advanced functionality, just indent and syntax support)**
|
||||||
20
.github/ISSUE_TEMPLATE/add-support-for-language.md
vendored
Normal file
20
.github/ISSUE_TEMPLATE/add-support-for-language.md
vendored
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
name: Add support for language
|
||||||
|
about: ''
|
||||||
|
title: ''
|
||||||
|
labels: ''
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
**Is your feature request related to a problem? Please describe.**
|
||||||
|
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
|
||||||
|
|
||||||
|
**Describe the solution you'd like**
|
||||||
|
A clear and concise description of what you want to happen.
|
||||||
|
|
||||||
|
**Describe alternatives you've considered**
|
||||||
|
A clear and concise description of any alternative solutions or features you've considered.
|
||||||
|
|
||||||
|
**Additional context**
|
||||||
|
Add any other context or screenshots about the feature request here.
|
||||||
16
.github/ISSUE_TEMPLATE/bug_report.md
vendored
Normal file
16
.github/ISSUE_TEMPLATE/bug_report.md
vendored
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
---
|
||||||
|
name: Bug report
|
||||||
|
about: Report vim-polyglot bug
|
||||||
|
title: ''
|
||||||
|
labels: ''
|
||||||
|
assignees: ''
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
<!-- Vim-polyglot is not responsible for bugs of plugins it uses. Please report only bugs that happen when plugin is used as part of vim-polyglot and doesn't happen when just install the plugin -->
|
||||||
|
|
||||||
|
**Does this bug happen when you install plugin without vim-polyglot?**
|
||||||
|
|
||||||
|
**Describe the bug:**
|
||||||
|
|
||||||
|
**To Reproduce:**
|
||||||
20
README.md
20
README.md
@@ -1,4 +1,6 @@
|
|||||||
# vim-polyglot [![Build Status][travis-img-url]][travis-url] []()
|

|
||||||
|
|
||||||
|
[![Build Status][travis-img-url]][travis-url] []()
|
||||||
|
|
||||||
[travis-img-url]: https://travis-ci.org/sheerun/vim-polyglot.svg
|
[travis-img-url]: https://travis-ci.org/sheerun/vim-polyglot.svg
|
||||||
[travis-url]: https://travis-ci.org/sheerun/vim-polyglot
|
[travis-url]: https://travis-ci.org/sheerun/vim-polyglot
|
||||||
@@ -8,7 +10,7 @@ A collection of language packs for Vim.
|
|||||||
> One to rule them all, one to find them, one to bring them all and in the darkness bind them.
|
> One to rule them all, one to find them, one to bring them all and in the darkness bind them.
|
||||||
|
|
||||||
- It **won't affect your startup time**, as scripts are loaded only on demand\*.
|
- It **won't affect your startup time**, as scripts are loaded only on demand\*.
|
||||||
- It **installs and updates 100+ times faster** than the <!--Package Count-->132<!--/Package Count--> packages it consists of.
|
- It **installs and updates 120+ times faster** than the <!--Package Count-->134<!--/Package Count--> packages it consists of.
|
||||||
- Solid syntax and indentation support (other features skipped). Only the best language packs.
|
- Solid syntax and indentation support (other features skipped). Only the best language packs.
|
||||||
- All unnecessary files are ignored (like enormous documentation from php support).
|
- All unnecessary files are ignored (like enormous documentation from php support).
|
||||||
- No support for esoteric languages, only most popular ones (modern too, like `slim`).
|
- No support for esoteric languages, only most popular ones (modern too, like `slim`).
|
||||||
@@ -82,7 +84,6 @@ If you need full functionality of any plugin, please use it directly with your p
|
|||||||
- [gnuplot](https://github.com/vim-scripts/gnuplot-syntax-highlighting) (syntax)
|
- [gnuplot](https://github.com/vim-scripts/gnuplot-syntax-highlighting) (syntax)
|
||||||
- [go](https://github.com/fatih/vim-go) (syntax, compiler, indent)
|
- [go](https://github.com/fatih/vim-go) (syntax, compiler, indent)
|
||||||
- [gradle](https://github.com/tfnico/vim-gradle) (compiler)
|
- [gradle](https://github.com/tfnico/vim-gradle) (compiler)
|
||||||
- [graphql](https://github.com/jparise/vim-graphql) (syntax, indent, ftplugin)
|
|
||||||
- [groovy-indent](https://github.com/vim-scripts/groovyindent-unix) (indent)
|
- [groovy-indent](https://github.com/vim-scripts/groovyindent-unix) (indent)
|
||||||
- [groovy](https://github.com/vim-scripts/groovy.vim) (syntax)
|
- [groovy](https://github.com/vim-scripts/groovy.vim) (syntax)
|
||||||
- [haml](https://github.com/sheerun/vim-haml) (syntax, indent, compiler, ftplugin)
|
- [haml](https://github.com/sheerun/vim-haml) (syntax, indent, compiler, ftplugin)
|
||||||
@@ -106,12 +107,12 @@ If you need full functionality of any plugin, please use it directly with your p
|
|||||||
- [latex](https://github.com/LaTeX-Box-Team/LaTeX-Box) (syntax, indent, ftplugin)
|
- [latex](https://github.com/LaTeX-Box-Team/LaTeX-Box) (syntax, indent, ftplugin)
|
||||||
- [less](https://github.com/groenewege/vim-less) (syntax, indent, ftplugin)
|
- [less](https://github.com/groenewege/vim-less) (syntax, indent, ftplugin)
|
||||||
- [lilypond](https://github.com/anowlcalledjosh/vim-lilypond) (syntax, indent, compiler, ftplugin)
|
- [lilypond](https://github.com/anowlcalledjosh/vim-lilypond) (syntax, indent, compiler, ftplugin)
|
||||||
- [liquid](https://github.com/tpope/vim-liquid) (syntax, indent, ftplugin)
|
|
||||||
- [livescript](https://github.com/gkz/vim-ls) (syntax, indent, compiler, ftplugin)
|
- [livescript](https://github.com/gkz/vim-ls) (syntax, indent, compiler, ftplugin)
|
||||||
|
- [llvm](https://github.com/rhysd/vim-llvm) (syntax, indent, ftplugin)
|
||||||
- [lua](https://github.com/tbastos/vim-lua) (syntax, indent)
|
- [lua](https://github.com/tbastos/vim-lua) (syntax, indent)
|
||||||
- [mako](https://github.com/sophacles/vim-bundle-mako) (syntax, indent, ftplugin)
|
- [mako](https://github.com/sophacles/vim-bundle-mako) (syntax, indent, ftplugin)
|
||||||
- [markdown](https://github.com/plasticboy/vim-markdown) (syntax, indent)
|
- [markdown](https://github.com/plasticboy/vim-markdown) (syntax, indent)
|
||||||
- [mathematica](https://github.com/rsmenon/vim-mathematica) (syntax, ftplugin)
|
- [mathematica](https://github.com/voldikss/vim-mma) (syntax, autoload, ftplugin)
|
||||||
- [mdx](https://github.com/jxnblk/vim-mdx-js) (syntax)
|
- [mdx](https://github.com/jxnblk/vim-mdx-js) (syntax)
|
||||||
- [meson](https://github.com/mesonbuild/meson) (syntax, indent, ftplugin)
|
- [meson](https://github.com/mesonbuild/meson) (syntax, indent, ftplugin)
|
||||||
- [moonscript](https://github.com/leafo/moonscript-vim) (syntax, indent, ftplugin)
|
- [moonscript](https://github.com/leafo/moonscript-vim) (syntax, indent, ftplugin)
|
||||||
@@ -123,7 +124,7 @@ If you need full functionality of any plugin, please use it directly with your p
|
|||||||
- [octave](https://github.com/vim-scripts/octave.vim--) (syntax)
|
- [octave](https://github.com/vim-scripts/octave.vim--) (syntax)
|
||||||
- [opencl](https://github.com/petRUShka/vim-opencl) (syntax, indent, ftplugin)
|
- [opencl](https://github.com/petRUShka/vim-opencl) (syntax, indent, ftplugin)
|
||||||
- [perl](https://github.com/vim-perl/vim-perl) (syntax, indent, ftplugin)
|
- [perl](https://github.com/vim-perl/vim-perl) (syntax, indent, ftplugin)
|
||||||
- [pgsql](https://github.com/exu/pgsql.vim) (syntax)
|
- [pgsql](https://github.com/lifepillar/pgsql.vim) (syntax, indent)
|
||||||
- [php](https://github.com/StanAngeloff/php.vim) (syntax)
|
- [php](https://github.com/StanAngeloff/php.vim) (syntax)
|
||||||
- [plantuml](https://github.com/aklt/plantuml-syntax) (syntax, indent, ftplugin)
|
- [plantuml](https://github.com/aklt/plantuml-syntax) (syntax, indent, ftplugin)
|
||||||
- [pony](https://github.com/jakwings/vim-pony) (syntax, indent, autoload, ftplugin)
|
- [pony](https://github.com/jakwings/vim-pony) (syntax, indent, autoload, ftplugin)
|
||||||
@@ -138,7 +139,7 @@ If you need full functionality of any plugin, please use it directly with your p
|
|||||||
- [qmake](https://github.com/artoj/qmake-syntax-vim) (syntax)
|
- [qmake](https://github.com/artoj/qmake-syntax-vim) (syntax)
|
||||||
- [qml](https://github.com/peterhoeg/vim-qml) (syntax, indent, ftplugin)
|
- [qml](https://github.com/peterhoeg/vim-qml) (syntax, indent, ftplugin)
|
||||||
- [r-lang](https://github.com/vim-scripts/R.vim) (syntax, ftplugin)
|
- [r-lang](https://github.com/vim-scripts/R.vim) (syntax, ftplugin)
|
||||||
- [racket](https://github.com/wlangstroth/vim-racket) (syntax, indent, autoload, ftplugin)
|
- [racket](https://github.com/wlangstroth/vim-racket) (syntax, indent, ftplugin)
|
||||||
- [ragel](https://github.com/jneen/ragel.vim) (syntax)
|
- [ragel](https://github.com/jneen/ragel.vim) (syntax)
|
||||||
- [raml](https://github.com/IN3D/vim-raml) (syntax, ftplugin)
|
- [raml](https://github.com/IN3D/vim-raml) (syntax, ftplugin)
|
||||||
- [reason](https://github.com/reasonml-editor/vim-reason-plus) (syntax, indent)
|
- [reason](https://github.com/reasonml-editor/vim-reason-plus) (syntax, indent)
|
||||||
@@ -148,12 +149,14 @@ If you need full functionality of any plugin, please use it directly with your p
|
|||||||
- [rust](https://github.com/rust-lang/rust.vim) (syntax, indent, compiler, autoload, ftplugin)
|
- [rust](https://github.com/rust-lang/rust.vim) (syntax, indent, compiler, autoload, ftplugin)
|
||||||
- [sbt](https://github.com/derekwyatt/vim-sbt) (syntax)
|
- [sbt](https://github.com/derekwyatt/vim-sbt) (syntax)
|
||||||
- [scala](https://github.com/derekwyatt/vim-scala) (syntax, indent, compiler, ftplugin)
|
- [scala](https://github.com/derekwyatt/vim-scala) (syntax, indent, compiler, ftplugin)
|
||||||
- [scss](https://github.com/cakebaker/scss-syntax.vim) (syntax, autoload, ftplugin)
|
- [scss](https://github.com/cakebaker/scss-syntax.vim) (syntax, indent, ftplugin)
|
||||||
- [slim](https://github.com/slim-template/vim-slim) (syntax, indent, ftplugin)
|
- [slim](https://github.com/slim-template/vim-slim) (syntax, indent, ftplugin)
|
||||||
- [slime](https://github.com/slime-lang/vim-slime-syntax) (syntax, indent)
|
- [slime](https://github.com/slime-lang/vim-slime-syntax) (syntax, indent)
|
||||||
- [smt2](https://github.com/bohlender/vim-smt2) (syntax, autoload, ftplugin)
|
- [smt2](https://github.com/bohlender/vim-smt2) (syntax, autoload, ftplugin)
|
||||||
- [solidity](https://github.com/tomlion/vim-solidity) (syntax, indent, ftplugin)
|
- [solidity](https://github.com/tomlion/vim-solidity) (syntax, indent, ftplugin)
|
||||||
- [stylus](https://github.com/wavded/vim-stylus) (syntax, indent, ftplugin)
|
- [stylus](https://github.com/wavded/vim-stylus) (syntax, indent, ftplugin)
|
||||||
|
- [svg-indent](https://github.com/jasonshell/vim-svg-indent) (indent)
|
||||||
|
- [svg](https://github.com/vim-scripts/svg.vim) (syntax)
|
||||||
- [swift](https://github.com/keith/swift.vim) (syntax, indent, ftplugin)
|
- [swift](https://github.com/keith/swift.vim) (syntax, indent, ftplugin)
|
||||||
- [sxhkd](https://github.com/baskerville/vim-sxhkdrc) (syntax)
|
- [sxhkd](https://github.com/baskerville/vim-sxhkdrc) (syntax)
|
||||||
- [systemd](https://github.com/wgwoods/vim-systemd-syntax) (syntax)
|
- [systemd](https://github.com/wgwoods/vim-systemd-syntax) (syntax)
|
||||||
@@ -171,6 +174,7 @@ If you need full functionality of any plugin, please use it directly with your p
|
|||||||
- [vifm](https://github.com/vifm/vifm.vim) (syntax, autoload, ftplugin)
|
- [vifm](https://github.com/vifm/vifm.vim) (syntax, autoload, ftplugin)
|
||||||
- [vm](https://github.com/lepture/vim-velocity) (syntax, indent)
|
- [vm](https://github.com/lepture/vim-velocity) (syntax, indent)
|
||||||
- [vue](https://github.com/posva/vim-vue) (syntax, indent, ftplugin)
|
- [vue](https://github.com/posva/vim-vue) (syntax, indent, ftplugin)
|
||||||
|
- [xdc](https://github.com/amal-khailtash/vim-xdc-syntax) (syntax)
|
||||||
- [xls](https://github.com/vim-scripts/XSLT-syntax) (syntax)
|
- [xls](https://github.com/vim-scripts/XSLT-syntax) (syntax)
|
||||||
- [xml](https://github.com/amadeus/vim-xml) (syntax)
|
- [xml](https://github.com/amadeus/vim-xml) (syntax)
|
||||||
- [yaml](https://github.com/stephpy/vim-yaml) (syntax, ftplugin)
|
- [yaml](https://github.com/stephpy/vim-yaml) (syntax, ftplugin)
|
||||||
|
|||||||
477
after/ftplugin/llvm.vim
Normal file
477
after/ftplugin/llvm.vim
Normal file
@@ -0,0 +1,477 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Copyright (c) 2018 rhysd
|
||||||
|
"
|
||||||
|
" Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
" of this software and associated documentation files (the "Software"), to deal
|
||||||
|
" in the Software without restriction, including without limitation the rights
|
||||||
|
" to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
" copies of the Software, and to permit persons to whom the Software is
|
||||||
|
" furnished to do so, subject to the following conditions:
|
||||||
|
"
|
||||||
|
" The above copyright notice and this permission notice shall be included in
|
||||||
|
" all copies or substantial portions of the Software.
|
||||||
|
"
|
||||||
|
" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
" AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
" OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
" THE SOFTWARE.
|
||||||
|
|
||||||
|
if get(g:, 'llvm_extends_official', 1) == 0
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
let g:llvm_ext_no_mapping = get(g:, 'llvm_ext_no_mapping', 0)
|
||||||
|
let g:llvm_ext_lli_executable = get(g:, 'llvm_ext_lli_executable', 'lli')
|
||||||
|
|
||||||
|
let s:KIND_BLOCK_PREC = 0
|
||||||
|
let s:KIND_BLOCK_FOLLOW = 1
|
||||||
|
let s:KIND_FUNC_BEGIN = 2
|
||||||
|
let s:KIND_FUNC_END = 3
|
||||||
|
|
||||||
|
function! s:section_delim_at(lnum) abort
|
||||||
|
let line = getline(a:lnum)
|
||||||
|
let m = matchlist(line, '^\([^:]\+\):\%( \+; preds = \(%.\+\)\)\=$')
|
||||||
|
if !empty(m)
|
||||||
|
if m[2] ==# ''
|
||||||
|
return [s:KIND_BLOCK_PREC, m[1]]
|
||||||
|
else
|
||||||
|
return [s:KIND_BLOCK_FOLLOW, m[1], split(m[2], ',\s*')]
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
if line =~# '^}$'
|
||||||
|
return [s:KIND_FUNC_END]
|
||||||
|
endif
|
||||||
|
if line =~# '^define\>'
|
||||||
|
return [s:KIND_FUNC_BEGIN]
|
||||||
|
endif
|
||||||
|
return []
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:is_section_delim(line, func_delim) abort
|
||||||
|
let sec = s:section_delim_at(a:line)
|
||||||
|
if empty(sec)
|
||||||
|
return 0
|
||||||
|
endif
|
||||||
|
let kind = sec[0]
|
||||||
|
return kind == s:KIND_BLOCK_PREC || kind == s:KIND_BLOCK_FOLLOW || kind == func_delim
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:next_section(stop_func_begin) abort
|
||||||
|
let func_delim = a:stop_func_begin ? s:KIND_FUNC_BEGIN : s:KIND_FUNC_END
|
||||||
|
let last = line('$') - 1
|
||||||
|
let line = line('.')
|
||||||
|
while line < last
|
||||||
|
let line += 1
|
||||||
|
if s:is_section_delim(line, func_delim)
|
||||||
|
call cursor(line, col('.'))
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
endwhile
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:prev_section(stop_func_begin) abort
|
||||||
|
let func_delim = a:stop_func_begin ? s:KIND_FUNC_BEGIN : s:KIND_FUNC_END
|
||||||
|
let line = line('.')
|
||||||
|
while line > 1
|
||||||
|
let line -= 1
|
||||||
|
if s:is_section_delim(line, func_delim)
|
||||||
|
call cursor(line, col('.'))
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
endwhile
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
if !g:llvm_ext_no_mapping
|
||||||
|
nnoremap <buffer><silent>]] :<C-u>call <SID>next_section(1)<CR>
|
||||||
|
nnoremap <buffer><silent>[[ :<C-u>call <SID>prev_section(1)<CR>
|
||||||
|
nnoremap <buffer><silent>][ :<C-u>call <SID>next_section(0)<CR>
|
||||||
|
nnoremap <buffer><silent>[] :<C-u>call <SID>prev_section(0)<CR>
|
||||||
|
endif
|
||||||
|
|
||||||
|
function! s:function_range_at(linum) abort
|
||||||
|
let line = a:linum
|
||||||
|
while line >= 1
|
||||||
|
let s = getline(line)
|
||||||
|
if s =~# '^define\>'
|
||||||
|
let start = line
|
||||||
|
break
|
||||||
|
elseif s =~# '^}$'
|
||||||
|
return []
|
||||||
|
endif
|
||||||
|
let line -= 1
|
||||||
|
endwhile
|
||||||
|
if line < 1
|
||||||
|
return []
|
||||||
|
endif
|
||||||
|
|
||||||
|
let line = a:linum
|
||||||
|
let last = line('$')
|
||||||
|
while line <= last
|
||||||
|
let s = getline(line)
|
||||||
|
if s =~# '^}$'
|
||||||
|
let end = line
|
||||||
|
break
|
||||||
|
elseif s =~# '^define\>'
|
||||||
|
return []
|
||||||
|
endif
|
||||||
|
let line += 1
|
||||||
|
endwhile
|
||||||
|
if line > last
|
||||||
|
return []
|
||||||
|
endif
|
||||||
|
|
||||||
|
return [start, end]
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:blocks_graph_at(linum) abort
|
||||||
|
let func_range = s:function_range_at(a:linum)
|
||||||
|
if empty(func_range)
|
||||||
|
return {}
|
||||||
|
endif
|
||||||
|
let line = func_range[0] + 1
|
||||||
|
let last = func_range[1] - 1
|
||||||
|
let graph = {}
|
||||||
|
while line <= last
|
||||||
|
let block = s:section_delim_at(line)
|
||||||
|
if empty(block)
|
||||||
|
let line += 1
|
||||||
|
continue
|
||||||
|
endif
|
||||||
|
let block_name = '%' . block[1]
|
||||||
|
if block[0] == s:KIND_BLOCK_PREC
|
||||||
|
let graph[block_name] = {'line': line, 'follows': [], 'preds': []}
|
||||||
|
elseif block[0] == s:KIND_BLOCK_FOLLOW
|
||||||
|
let graph[block_name] = {'line': line, 'follows': [], 'preds': block[2]}
|
||||||
|
for follow in block[2]
|
||||||
|
call add(graph[follow].follows, block_name)
|
||||||
|
endfor
|
||||||
|
else
|
||||||
|
echoerr 'unreachable'
|
||||||
|
endif
|
||||||
|
let line += 1
|
||||||
|
endwhile
|
||||||
|
return graph
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:find_pred_block(linum) abort
|
||||||
|
let sec = s:section_delim_at(a:linum)
|
||||||
|
if empty(sec) || sec[0] != s:KIND_BLOCK_PREC && sec[0] != s:KIND_BLOCK_FOLLOW
|
||||||
|
throw 'No block is starting at line ' . a:linum
|
||||||
|
endif
|
||||||
|
if sec[0] != s:KIND_BLOCK_FOLLOW
|
||||||
|
throw printf("Block '%s' has no pred block", sec[1])
|
||||||
|
endif
|
||||||
|
let block_name = '%' . sec[1]
|
||||||
|
let pred_block = sec[2][0]
|
||||||
|
|
||||||
|
let graph = s:blocks_graph_at(a:linum)
|
||||||
|
if empty(graph)
|
||||||
|
throw 'No block is found in function at line ' . a:linum
|
||||||
|
endif
|
||||||
|
|
||||||
|
if !has_key(graph, pred_block)
|
||||||
|
throw printf("Block '%s' (pred block of '%s') not found in function", pred_block, block_name)
|
||||||
|
endif
|
||||||
|
return graph[pred_block]
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:move_to_pred_block() abort
|
||||||
|
try
|
||||||
|
let b = s:find_pred_block(line('.'))
|
||||||
|
call cursor(b.line, col('.'))
|
||||||
|
catch
|
||||||
|
echohl ErrorMsg | echom v:exception | echohl None
|
||||||
|
endtry
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:find_following_block(linum) abort
|
||||||
|
let sec = s:section_delim_at(a:linum)
|
||||||
|
if empty(sec) || sec[0] != s:KIND_BLOCK_PREC && sec[0] != s:KIND_BLOCK_FOLLOW
|
||||||
|
throw 'No block is starting at line ' . a:linum
|
||||||
|
endif
|
||||||
|
let block_name = '%' . sec[1]
|
||||||
|
|
||||||
|
let graph = s:blocks_graph_at(a:linum)
|
||||||
|
if empty(graph)
|
||||||
|
throw 'No block is found in function at line ' . a:linum
|
||||||
|
endif
|
||||||
|
|
||||||
|
let follows = graph[block_name].follows
|
||||||
|
if empty(follows)
|
||||||
|
throw printf("Block '%s' has no following block", block_name)
|
||||||
|
endif
|
||||||
|
|
||||||
|
echom printf("Block '%s' has %d following blocks: %s", block_name, len(follows), join(follows, ', '))
|
||||||
|
|
||||||
|
if !has_key(graph, follows[0])
|
||||||
|
throw printf("Block '%s' is not defined in function at line %d", follows[0], a:linum)
|
||||||
|
endif
|
||||||
|
return graph[follows[0]]
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:move_to_following_block() abort
|
||||||
|
try
|
||||||
|
let b = s:find_following_block(line('.'))
|
||||||
|
call cursor(b.line, col('.'))
|
||||||
|
catch
|
||||||
|
echohl ErrorMsg | echom v:exception | echohl None
|
||||||
|
endtry
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
if !g:llvm_ext_no_mapping
|
||||||
|
nnoremap <buffer><silent>[b :<C-u>call <SID>move_to_pred_block()<CR>
|
||||||
|
nnoremap <buffer><silent>]b :<C-u>call <SID>move_to_following_block()<CR>
|
||||||
|
endif
|
||||||
|
|
||||||
|
function! s:get_func_identifiers(line) abort
|
||||||
|
let idx = stridx(a:line, '@')
|
||||||
|
if idx == -1
|
||||||
|
" Invalid signature
|
||||||
|
return []
|
||||||
|
endif
|
||||||
|
|
||||||
|
" e.g. define internal i32 @foo(...) { -> @foo(...) {
|
||||||
|
let sig = a:line[idx:]
|
||||||
|
|
||||||
|
let idx = stridx(sig, '(')
|
||||||
|
if idx == -1
|
||||||
|
" Invalid signature
|
||||||
|
return []
|
||||||
|
endif
|
||||||
|
|
||||||
|
" @foo(...) { -> @foo
|
||||||
|
let idents = [sig[:idx-1]]
|
||||||
|
|
||||||
|
" @foo(...) { -> ...) {
|
||||||
|
let params = sig[idx+1:]
|
||||||
|
|
||||||
|
let idx = strridx(sig, ')')
|
||||||
|
if idx == -1
|
||||||
|
return idents
|
||||||
|
endif
|
||||||
|
|
||||||
|
" ...) { -> ...
|
||||||
|
let params = params[:idx-1]
|
||||||
|
|
||||||
|
" Gather parameters in function signature
|
||||||
|
while params !=# ''
|
||||||
|
let m = matchlist(params, '^[^%]*\(%\%("[^"]\+"\|[[:alnum:]_.]\+\)\)\s*\(.*\)$')
|
||||||
|
if empty(m)
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
let idents += [m[1]]
|
||||||
|
let params = m[2]
|
||||||
|
endwhile
|
||||||
|
|
||||||
|
return idents
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:get_identifiers(line) abort
|
||||||
|
" Registers and type defs
|
||||||
|
let m = matchlist(a:line, '^\s*\(%\S\+\)\s\+=')
|
||||||
|
if !empty(m)
|
||||||
|
return [m[1]]
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Constants
|
||||||
|
let m = matchlist(a:line, '^\(@\S\+\)\s\+=.\+\<constant\>')
|
||||||
|
if !empty(m)
|
||||||
|
return [m[1]]
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Labels for basic blocks
|
||||||
|
let m = matchlist(a:line, '^\([^:]\+\):\%(\s\+; preds = .\+\)\=$')
|
||||||
|
if !empty(m)
|
||||||
|
return ['%' . m[1]]
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Meta variables
|
||||||
|
let m = matchlist(a:line, '^\(!\S\+\)\s\+=')
|
||||||
|
if !empty(m)
|
||||||
|
return [m[1]]
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Attributes
|
||||||
|
let m = matchlist(a:line, '^attributes\s\+\(#\d\+\)\s\+=')
|
||||||
|
if !empty(m)
|
||||||
|
return [m[1]]
|
||||||
|
endif
|
||||||
|
|
||||||
|
if a:line =~# '^\%(declare\|define\)\>'
|
||||||
|
return s:get_func_identifiers(a:line)
|
||||||
|
endif
|
||||||
|
|
||||||
|
return []
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:extract_identifier(word) abort
|
||||||
|
if strlen(a:word) <= 1
|
||||||
|
return ''
|
||||||
|
endif
|
||||||
|
|
||||||
|
let prefix = a:word[0]
|
||||||
|
if prefix ==# '@' || prefix ==# '%' || prefix ==# '!'
|
||||||
|
if prefix ==# '!' && a:word[1] ==# '{'
|
||||||
|
return ''
|
||||||
|
endif
|
||||||
|
|
||||||
|
if a:word[1] == '"'
|
||||||
|
let idx = stridx(a:word, '"', 2)
|
||||||
|
if idx == -1
|
||||||
|
return ''
|
||||||
|
endif
|
||||||
|
" @"foo" or %"foo"
|
||||||
|
return a:word[:idx]
|
||||||
|
else
|
||||||
|
" @foo or %foo
|
||||||
|
return matchstr(a:word, '^[@%!][[:alnum:]_.]\+')
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
if prefix ==# '#'
|
||||||
|
return matchstr(a:word, '^#\d\+')
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ''
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:jump_to_identifier_at(linum, ident) abort
|
||||||
|
let line = getline(a:linum)
|
||||||
|
let column = stridx(line, a:ident) + 1
|
||||||
|
if column == 0
|
||||||
|
let column = col('.')
|
||||||
|
endif
|
||||||
|
call cursor(a:linum, column)
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:browser_open_command() abort
|
||||||
|
if exists('g:llvm_ext_browser_open_command')
|
||||||
|
return g:llvm_ext_browser_open_command
|
||||||
|
endif
|
||||||
|
if exists('s:browser_opener')
|
||||||
|
return s:browser_opener
|
||||||
|
endif
|
||||||
|
let s:browser_opener = ''
|
||||||
|
if has('mac')
|
||||||
|
let s:browser_opener = 'open'
|
||||||
|
elseif has('win32') || has('win64')
|
||||||
|
let s:browser_opener = 'cmd /q /c start ""'
|
||||||
|
else
|
||||||
|
for cmd in ['xdg-open', 'chromium', 'google-chrome', 'firefox']
|
||||||
|
if executable(cmd)
|
||||||
|
let s:browser_opener = cmd
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
|
endif
|
||||||
|
return s:browser_opener
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:open_browser(url) abort
|
||||||
|
let cmd = s:browser_open_command()
|
||||||
|
if cmd ==# ''
|
||||||
|
throw "Failed to open a browser. I don't know how to open a browser: Please set g:llvm_ext_browser_open_command"
|
||||||
|
endif
|
||||||
|
let cmdline = cmd . ' ' . shellescape(a:url)
|
||||||
|
let out = system(cmdline)
|
||||||
|
if v:shell_error
|
||||||
|
throw printf("Failed to open a browser with command '%s': %s", cmdline, out)
|
||||||
|
endif
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:goto_definition() abort
|
||||||
|
" Open language reference manual under the cursor in browser
|
||||||
|
let syn_name = synIDattr(synID(line('.'),col('.'),1),'name')
|
||||||
|
if syn_name ==# 'llvmStatement'
|
||||||
|
let word = expand('<cword>')
|
||||||
|
if word !=# ''
|
||||||
|
try
|
||||||
|
" Open browser assuming a word under the cursor is an instruction
|
||||||
|
call s:open_browser('https://llvm.org/docs/LangRef.html#' . word . '-instruction')
|
||||||
|
catch /^Failed to open a browser/
|
||||||
|
echohl ErrorMsg | echom v:exception | echohl None
|
||||||
|
endtry
|
||||||
|
endif
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
|
||||||
|
" XXX: This does not support identifiers which contains spaces
|
||||||
|
let word = expand('<cWORD>')
|
||||||
|
if word ==# ''
|
||||||
|
echom 'No identifier found under the cursor'
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
let ident = s:extract_identifier(word)
|
||||||
|
if ident ==# ''
|
||||||
|
echom 'No identifier found under the cursor'
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Definition tends to be near its usages. Look back at first.
|
||||||
|
let line = line('.')
|
||||||
|
while line > 0
|
||||||
|
for found in s:get_identifiers(getline(line))
|
||||||
|
if ident ==# found
|
||||||
|
call s:jump_to_identifier_at(line, ident)
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
|
let line -= 1
|
||||||
|
endwhile
|
||||||
|
|
||||||
|
let line = line('.') + 1
|
||||||
|
let last = line('$')
|
||||||
|
while line <= last
|
||||||
|
for found in s:get_identifiers(getline(line))
|
||||||
|
if ident ==# found
|
||||||
|
call s:jump_to_identifier_at(line, ident)
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
|
let line += 1
|
||||||
|
endwhile
|
||||||
|
|
||||||
|
echom "No definition for '" . ident . "' found"
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
if !g:llvm_ext_no_mapping
|
||||||
|
nnoremap <buffer><silent>K :<C-u>call <SID>goto_definition()<CR>
|
||||||
|
endif
|
||||||
|
|
||||||
|
function! s:run_lli(...) abort
|
||||||
|
if !has('job') || !has('channel') || !has('terminal')
|
||||||
|
echohl ErrorMsg
|
||||||
|
echomsg ':LLI requires terminal feature. Please update your Vim to 8.0+'
|
||||||
|
echohl None
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
|
||||||
|
if !executable(g:llvm_ext_lli_executable)
|
||||||
|
echohl ErrorMsg
|
||||||
|
echomsg g:llvm_ext_lli_executable . ' is not executable. Please set g:llvm_ext_lli_executable'
|
||||||
|
echohl None
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
|
||||||
|
if a:0 > 0
|
||||||
|
let bufnr = term_start([g:llvm_ext_lli_executable, a:1])
|
||||||
|
echo 'Run lli in termnal buffer(' . bufnr . ')'
|
||||||
|
return
|
||||||
|
endif
|
||||||
|
|
||||||
|
let tmpfile = tempname()
|
||||||
|
call writefile(getline(1, '$'), tmpfile)
|
||||||
|
let Cleanup = {ch -> filereadable(tmpfile) ? delete(tmpfile) : 0}
|
||||||
|
let bufnr = term_start([g:llvm_ext_lli_executable, tmpfile], {'close_cb': Cleanup, 'exit_cb': Cleanup})
|
||||||
|
echo 'Run lli in termnal buffer(' . bufnr . ')'
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
if !exists(':LLI')
|
||||||
|
command! -buffer -nargs=? -bar -complete=file LLI call <SID>run_lli(<f-args>)
|
||||||
|
endif
|
||||||
@@ -1,27 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'graphql') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
if exists('b:current_syntax')
|
|
||||||
let s:current_syntax = b:current_syntax
|
|
||||||
unlet b:current_syntax
|
|
||||||
endif
|
|
||||||
syn include @GraphQLSyntax syntax/graphql.vim
|
|
||||||
if exists('s:current_syntax')
|
|
||||||
let b:current_syntax = s:current_syntax
|
|
||||||
endif
|
|
||||||
|
|
||||||
let s:tags = '\%(' . join(g:graphql_javascript_tags, '\|') . '\)'
|
|
||||||
|
|
||||||
exec 'syntax region graphqlTemplateString start=+' . s:tags . '\@20<=`+ skip=+\\`+ end=+`+ contains=@GraphQLSyntax,jsTemplateExpression,jsSpecial extend'
|
|
||||||
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
|
|
||||||
|
|
||||||
" Support expression interpolation ((${...})) inside template strings.
|
|
||||||
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=jsTemplateExpression containedin=graphqlFold keepend
|
|
||||||
|
|
||||||
hi def link graphqlTemplateString jsTemplateString
|
|
||||||
hi def link graphqlTaggedTemplate jsTaggedTemplate
|
|
||||||
hi def link graphqlTemplateExpression jsTemplateExpression
|
|
||||||
|
|
||||||
syn cluster jsExpression add=graphqlTaggedTemplate
|
|
||||||
syn cluster graphqlTaggedTemplate add=graphqlTemplateString
|
|
||||||
26
after/syntax/llvm.vim
Normal file
26
after/syntax/llvm.vim
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Copyright (c) 2018 rhysd
|
||||||
|
"
|
||||||
|
" Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
" of this software and associated documentation files (the "Software"), to deal
|
||||||
|
" in the Software without restriction, including without limitation the rights
|
||||||
|
" to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
" copies of the Software, and to permit persons to whom the Software is
|
||||||
|
" furnished to do so, subject to the following conditions:
|
||||||
|
"
|
||||||
|
" The above copyright notice and this permission notice shall be included in
|
||||||
|
" all copies or substantial portions of the Software.
|
||||||
|
"
|
||||||
|
" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||||
|
" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||||
|
" AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||||
|
" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||||
|
" OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||||
|
" THE SOFTWARE.
|
||||||
|
|
||||||
|
syn keyword llvmKeyword attributes
|
||||||
|
syn match llvmNoName /#\d\+\>/
|
||||||
1469
after/syntax/mma.vim
1469
after/syntax/mma.vim
File diff suppressed because it is too large
Load Diff
@@ -1,26 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'graphql') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
if exists('b:current_syntax')
|
|
||||||
let s:current_syntax = b:current_syntax
|
|
||||||
unlet b:current_syntax
|
|
||||||
endif
|
|
||||||
syn include @GraphQLSyntax syntax/graphql.vim
|
|
||||||
if exists('s:current_syntax')
|
|
||||||
let b:current_syntax = s:current_syntax
|
|
||||||
endif
|
|
||||||
|
|
||||||
let s:tags = '\%(' . join(g:graphql_javascript_tags, '\|') . '\)'
|
|
||||||
|
|
||||||
exec 'syntax region graphqlTemplateString start=+' . s:tags . '\@20<=`+ skip=+\\`+ end=+`+ contains=@GraphQLSyntax,typescriptTemplateSubstitution extend'
|
|
||||||
exec 'syntax match graphqlTaggedTemplate +' . s:tags . '\ze`+ nextgroup=graphqlTemplateString'
|
|
||||||
|
|
||||||
" Support expression interpolation ((${...})) inside template strings.
|
|
||||||
syntax region graphqlTemplateExpression start=+${+ end=+}+ contained contains=typescriptTemplateSubstitution containedin=graphqlFold keepend
|
|
||||||
|
|
||||||
hi def link graphqlTemplateString typescriptTemplate
|
|
||||||
hi def link graphqlTemplateExpression typescriptTemplateSubstitution
|
|
||||||
|
|
||||||
syn cluster typescriptExpression add=graphqlTaggedTemplate
|
|
||||||
syn cluster graphqlTaggedTemplate add=graphqlTemplateString
|
|
||||||
7437
autoload/coc/source/mma.vim
Normal file
7437
autoload/coc/source/mma.vim
Normal file
File diff suppressed because it is too large
Load Diff
@@ -37,21 +37,45 @@ function! s:run_cmd(cmd) abort
|
|||||||
return s:P.system(a:cmd)
|
return s:P.system(a:cmd)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:find_root_by_spec(d) abort
|
function! s:find_root_by(search_dir, d) abort
|
||||||
let dir = finddir('spec', a:d . ';')
|
let found_dir = finddir(a:search_dir, a:d . ';')
|
||||||
if dir ==# ''
|
if found_dir ==# ''
|
||||||
return ''
|
return ''
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Note: ':h:h' for {root}/spec/ -> {root}/spec -> {root}
|
" Note: ':h:h' for {root}/{search_dir}/ -> {root}/{search_dir} -> {root}
|
||||||
return fnamemodify(dir, ':p:h:h')
|
return fnamemodify(found_dir, ':p:h:h')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
" Search the root directory containing a 'spec/' and a 'src/' directories.
|
||||||
|
"
|
||||||
|
" Searching for the 'spec/' directory is not enough: for example the crystal
|
||||||
|
" compiler has a 'cr_sources/src/spec/' directory that would otherwise give the root
|
||||||
|
" directory as 'cr_source/src/' instead of 'cr_sources/'.
|
||||||
|
function! s:find_root_by_spec_and_src(d) abort
|
||||||
|
" Search for 'spec/'
|
||||||
|
let root = s:find_root_by('spec', a:d)
|
||||||
|
" Check that 'src/' is also there
|
||||||
|
if root !=# '' && isdirectory(root . '/src')
|
||||||
|
return root
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Search for 'src/'
|
||||||
|
let root = s:find_root_by('src', a:d)
|
||||||
|
" Check that 'spec/' is also there
|
||||||
|
if root !=# '' && isdirectory(root . '/spec')
|
||||||
|
return root
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Cannot find a directory containing both 'src/' and 'spec/'
|
||||||
|
return ''
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! crystal_lang#entrypoint_for(file_path) abort
|
function! crystal_lang#entrypoint_for(file_path) abort
|
||||||
let parent_dir = fnamemodify(a:file_path, ':p:h')
|
let parent_dir = fnamemodify(a:file_path, ':p:h')
|
||||||
let root_dir = s:find_root_by_spec(parent_dir)
|
let root_dir = s:find_root_by_spec_and_src(parent_dir)
|
||||||
if root_dir ==# ''
|
if root_dir ==# ''
|
||||||
" No spec diretory found. No need to make temporary file
|
" No spec directory found. No need to make temporary file
|
||||||
return a:file_path
|
return a:file_path
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -232,7 +256,7 @@ endfunction
|
|||||||
|
|
||||||
function! crystal_lang#run_all_spec(...) abort
|
function! crystal_lang#run_all_spec(...) abort
|
||||||
let path = a:0 == 0 ? expand('%:p:h') : a:1
|
let path = a:0 == 0 ? expand('%:p:h') : a:1
|
||||||
let root_path = s:find_root_by_spec(path)
|
let root_path = s:find_root_by_spec_and_src(path)
|
||||||
if root_path ==# ''
|
if root_path ==# ''
|
||||||
return s:echo_error("'spec' directory is not found")
|
return s:echo_error("'spec' directory is not found")
|
||||||
endif
|
endif
|
||||||
@@ -250,9 +274,9 @@ function! crystal_lang#run_current_spec(...) abort
|
|||||||
let source_dir = fnamemodify(path, ':h')
|
let source_dir = fnamemodify(path, ':h')
|
||||||
|
|
||||||
" /foo/bar
|
" /foo/bar
|
||||||
let root_dir = s:find_root_by_spec(source_dir)
|
let root_dir = s:find_root_by_spec_and_src(source_dir)
|
||||||
if root_dir ==# ''
|
if root_dir ==# ''
|
||||||
return s:echo_error("'spec' directory is not found")
|
return s:echo_error("Root directory with 'src/' and 'spec/' not found")
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" src
|
" src
|
||||||
|
|||||||
24
autoload/db/adapter/ecto.vim
Normal file
24
autoload/db/adapter/ecto.vim
Normal file
@@ -0,0 +1,24 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'elixir') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
let s:path = expand('<sfile>:h')
|
||||||
|
let s:cmd = join(['mix', 'run', '--no-start', '--no-compile', shellescape(s:path.'/get_repos.exs')])
|
||||||
|
|
||||||
|
function! s:repo_list() abort
|
||||||
|
return map(systemlist(s:cmd), 'split(v:val)')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! db#adapter#ecto#canonicalize(url) abort
|
||||||
|
for l:item in s:repo_list()
|
||||||
|
let l:name = get(l:item, 0)
|
||||||
|
let l:url = get(l:item, 1)
|
||||||
|
if !empty(l:name) && 'ecto:'.l:name ==# a:url
|
||||||
|
return l:url
|
||||||
|
endif
|
||||||
|
endfor
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! db#adapter#ecto#complete_opaque(url) abort
|
||||||
|
return map(s:repo_list(), 'v:val[0]')
|
||||||
|
endfunction
|
||||||
@@ -136,7 +136,13 @@ function! elm#util#GoToModule(name)
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! s:findLocalModule(rel_path, root)
|
function! s:findLocalModule(rel_path, root)
|
||||||
let l:package_json = a:root . '/elm-package.json'
|
let l:old_match = findfile('elm-package.json', a:root . ';')
|
||||||
|
let l:new_match = findfile('elm.json', a:root . ';')
|
||||||
|
if !empty(l:new_match)
|
||||||
|
let l:package_json = l:new_match
|
||||||
|
elseif !empty(l:old_match)
|
||||||
|
let l:package_json = l:old_match
|
||||||
|
endif
|
||||||
if exists('*json_decode')
|
if exists('*json_decode')
|
||||||
let l:package = json_decode(readfile(l:package_json))
|
let l:package = json_decode(readfile(l:package_json))
|
||||||
let l:source_roots = l:package['source-directories']
|
let l:source_roots = l:package['source-directories']
|
||||||
|
|||||||
@@ -52,7 +52,7 @@ function! go#config#TermMode() abort
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! go#config#TermEnabled() abort
|
function! go#config#TermEnabled() abort
|
||||||
return get(g:, 'go_term_enabled', 0)
|
return has('nvim') && get(g:, 'go_term_enabled', 0)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! go#config#SetTermEnabled(value) abort
|
function! go#config#SetTermEnabled(value) abort
|
||||||
@@ -214,6 +214,16 @@ function! go#config#DebugCommands() abort
|
|||||||
return g:go_debug_commands
|
return g:go_debug_commands
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
function! go#config#DebugLogOutput() abort
|
||||||
|
return get(g:, 'go_debug_log_output', 'debugger, rpc')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! go#config#LspLog() abort
|
||||||
|
" make sure g:go_lsp_log is set so that it can be added to easily.
|
||||||
|
let g:go_lsp_log = get(g:, 'go_lsp_log', [])
|
||||||
|
return g:go_lsp_log
|
||||||
|
endfunction
|
||||||
|
|
||||||
function! go#config#SetDebugDiag(value) abort
|
function! go#config#SetDebugDiag(value) abort
|
||||||
let g:go_debug_diag = a:value
|
let g:go_debug_diag = a:value
|
||||||
endfunction
|
endfunction
|
||||||
@@ -239,15 +249,27 @@ function! go#config#SetTemplateAutocreate(value) abort
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! go#config#MetalinterCommand() abort
|
function! go#config#MetalinterCommand() abort
|
||||||
return get(g:, "go_metalinter_command", "")
|
return get(g:, "go_metalinter_command", "gometalinter")
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! go#config#MetalinterAutosaveEnabled() abort
|
function! go#config#MetalinterAutosaveEnabled() abort
|
||||||
return get(g:, 'go_metalinter_autosave_enabled', ['vet', 'golint'])
|
let l:default_enabled = ["vet", "golint"]
|
||||||
|
|
||||||
|
if go#config#MetalinterCommand() == "golangci-lint"
|
||||||
|
let l:default_enabled = ["govet", "golint"]
|
||||||
|
endif
|
||||||
|
|
||||||
|
return get(g:, "go_metalinter_autosave_enabled", default_enabled)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! go#config#MetalinterEnabled() abort
|
function! go#config#MetalinterEnabled() abort
|
||||||
return get(g:, "go_metalinter_enabled", ['vet', 'golint', 'errcheck'])
|
let l:default_enabled = ["vet", "golint", "errcheck"]
|
||||||
|
|
||||||
|
if go#config#MetalinterCommand() == "golangci-lint"
|
||||||
|
let l:default_enabled = ["govet", "golint"]
|
||||||
|
endif
|
||||||
|
|
||||||
|
return get(g:, "go_metalinter_enabled", default_enabled)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! go#config#MetalinterDisabled() abort
|
function! go#config#MetalinterDisabled() abort
|
||||||
@@ -448,7 +470,6 @@ function! go#config#EchoGoInfo() abort
|
|||||||
return get(g:, "go_echo_go_info", 1)
|
return get(g:, "go_echo_go_info", 1)
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
" Set the default value. A value of "1" is a shortcut for this, for
|
" Set the default value. A value of "1" is a shortcut for this, for
|
||||||
" compatibility reasons.
|
" compatibility reasons.
|
||||||
if exists("g:go_gorename_prefill") && g:go_gorename_prefill == 1
|
if exists("g:go_gorename_prefill") && g:go_gorename_prefill == 1
|
||||||
|
|||||||
@@ -1,7 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'racket') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists("g:raco_command")
|
|
||||||
let g:raco_command = system("which raco")
|
|
||||||
endif
|
|
||||||
@@ -149,6 +149,7 @@ function! s:RunRustfmt(command, tmpname, fail_silently)
|
|||||||
|
|
||||||
call delete(l:stderr_tmpname)
|
call delete(l:stderr_tmpname)
|
||||||
|
|
||||||
|
let l:open_lwindow = 0
|
||||||
if v:shell_error == 0
|
if v:shell_error == 0
|
||||||
" remove undo point caused via BufWritePre
|
" remove undo point caused via BufWritePre
|
||||||
try | silent undojoin | catch | endtry
|
try | silent undojoin | catch | endtry
|
||||||
@@ -169,7 +170,7 @@ function! s:RunRustfmt(command, tmpname, fail_silently)
|
|||||||
if s:got_fmt_error
|
if s:got_fmt_error
|
||||||
let s:got_fmt_error = 0
|
let s:got_fmt_error = 0
|
||||||
call setloclist(0, [])
|
call setloclist(0, [])
|
||||||
lwindow
|
let l:open_lwindow = 1
|
||||||
endif
|
endif
|
||||||
elseif g:rustfmt_fail_silently == 0 && a:fail_silently == 0
|
elseif g:rustfmt_fail_silently == 0 && a:fail_silently == 0
|
||||||
" otherwise get the errors and put them in the location list
|
" otherwise get the errors and put them in the location list
|
||||||
@@ -201,7 +202,7 @@ function! s:RunRustfmt(command, tmpname, fail_silently)
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
let s:got_fmt_error = 1
|
let s:got_fmt_error = 1
|
||||||
lwindow
|
let l:open_lwindow = 1
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Restore the current directory if needed
|
" Restore the current directory if needed
|
||||||
@@ -213,6 +214,11 @@ function! s:RunRustfmt(command, tmpname, fail_silently)
|
|||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
" Open lwindow after we have changed back to the previous directory
|
||||||
|
if l:open_lwindow == 1
|
||||||
|
lwindow
|
||||||
|
endif
|
||||||
|
|
||||||
silent! loadview
|
silent! loadview
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
@@ -234,6 +240,9 @@ function! rustfmt#Cmd()
|
|||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
function! rustfmt#PreWrite()
|
function! rustfmt#PreWrite()
|
||||||
|
if !filereadable(expand("%@"))
|
||||||
|
return
|
||||||
|
endif
|
||||||
if rust#GetConfigVar('rustfmt_autosave_if_config_present', 0)
|
if rust#GetConfigVar('rustfmt_autosave_if_config_present', 0)
|
||||||
if findfile('rustfmt.toml', '.;') !=# '' || findfile('.rustfmt.toml', '.;') !=# ''
|
if findfile('rustfmt.toml', '.;') !=# '' || findfile('.rustfmt.toml', '.;') !=# ''
|
||||||
let b:rustfmt_autosave = 1
|
let b:rustfmt_autosave = 1
|
||||||
|
|||||||
@@ -1,41 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'scss') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" usage:
|
|
||||||
" set indentexpr=scss_indent#GetIndent(v:lnum)
|
|
||||||
fun! scss_indent#GetIndent(lnum)
|
|
||||||
" { -> increase indent
|
|
||||||
" } -> decrease indent
|
|
||||||
if a:lnum == 1
|
|
||||||
" start at 0 indentation
|
|
||||||
return 0
|
|
||||||
endif
|
|
||||||
|
|
||||||
" try to find last line ending with { or }
|
|
||||||
" ignoring // comments
|
|
||||||
let regex = '\([{}]\)\%(\/\/.*\)\?$'
|
|
||||||
let nr = search(regex, 'bnW')
|
|
||||||
if nr > 0
|
|
||||||
let last = indent(nr)
|
|
||||||
let m = matchlist(getline(nr), regex)
|
|
||||||
let m_curr = matchlist(getline(a:lnum), regex)
|
|
||||||
echoe string(m).string(m_curr)
|
|
||||||
if !empty(m_curr) && m_curr[1] == '}' && m[1] == '{'
|
|
||||||
" last was open, current is close, use same indent
|
|
||||||
return last
|
|
||||||
elseif !empty(m_curr) && m_curr[1] == '}' && m[1] == '}'
|
|
||||||
" } line and last line was }: decrease
|
|
||||||
return last - &sw
|
|
||||||
endif
|
|
||||||
if m[1] == '{'
|
|
||||||
" line after {: increase indent
|
|
||||||
return last + &sw
|
|
||||||
else
|
|
||||||
" line after } or { - same indent
|
|
||||||
return last
|
|
||||||
endif
|
|
||||||
else
|
|
||||||
return 0
|
|
||||||
endif
|
|
||||||
endfun
|
|
||||||
10
build
10
build
@@ -192,7 +192,6 @@ PACKS="
|
|||||||
gnuplot:vim-scripts/gnuplot-syntax-highlighting
|
gnuplot:vim-scripts/gnuplot-syntax-highlighting
|
||||||
go:fatih/vim-go:_BASIC
|
go:fatih/vim-go:_BASIC
|
||||||
gradle:tfnico/vim-gradle
|
gradle:tfnico/vim-gradle
|
||||||
graphql:jparise/vim-graphql
|
|
||||||
groovy:vim-scripts/groovy.vim
|
groovy:vim-scripts/groovy.vim
|
||||||
groovy-indent:vim-scripts/groovyindent-unix
|
groovy-indent:vim-scripts/groovyindent-unix
|
||||||
haml:sheerun/vim-haml
|
haml:sheerun/vim-haml
|
||||||
@@ -215,13 +214,13 @@ PACKS="
|
|||||||
kotlin:udalov/kotlin-vim
|
kotlin:udalov/kotlin-vim
|
||||||
latex:LaTeX-Box-Team/LaTeX-Box
|
latex:LaTeX-Box-Team/LaTeX-Box
|
||||||
less:groenewege/vim-less:_NOAFTER
|
less:groenewege/vim-less:_NOAFTER
|
||||||
liquid:tpope/vim-liquid
|
|
||||||
lilypond:anowlcalledjosh/vim-lilypond
|
lilypond:anowlcalledjosh/vim-lilypond
|
||||||
livescript:gkz/vim-ls
|
livescript:gkz/vim-ls
|
||||||
|
llvm:rhysd/vim-llvm
|
||||||
lua:tbastos/vim-lua
|
lua:tbastos/vim-lua
|
||||||
mako:sophacles/vim-bundle-mako
|
mako:sophacles/vim-bundle-mako
|
||||||
markdown:plasticboy/vim-markdown:_SYNTAX
|
markdown:plasticboy/vim-markdown:_SYNTAX
|
||||||
mathematica:rsmenon/vim-mathematica
|
mathematica:voldikss/vim-mma
|
||||||
mdx:jxnblk/vim-mdx-js
|
mdx:jxnblk/vim-mdx-js
|
||||||
meson:mesonbuild/meson:_ALL:/data/syntax-highlighting/vim/
|
meson:mesonbuild/meson:_ALL:/data/syntax-highlighting/vim/
|
||||||
moonscript:leafo/moonscript-vim
|
moonscript:leafo/moonscript-vim
|
||||||
@@ -233,7 +232,7 @@ PACKS="
|
|||||||
octave:vim-scripts/octave.vim--
|
octave:vim-scripts/octave.vim--
|
||||||
opencl:petRUShka/vim-opencl
|
opencl:petRUShka/vim-opencl
|
||||||
perl:vim-perl/vim-perl
|
perl:vim-perl/vim-perl
|
||||||
pgsql:exu/pgsql.vim
|
pgsql:lifepillar/pgsql.vim
|
||||||
php:StanAngeloff/php.vim
|
php:StanAngeloff/php.vim
|
||||||
plantuml:aklt/plantuml-syntax
|
plantuml:aklt/plantuml-syntax
|
||||||
pony:jakwings/vim-pony
|
pony:jakwings/vim-pony
|
||||||
@@ -264,6 +263,8 @@ PACKS="
|
|||||||
smt2:bohlender/vim-smt2
|
smt2:bohlender/vim-smt2
|
||||||
solidity:tomlion/vim-solidity
|
solidity:tomlion/vim-solidity
|
||||||
stylus:wavded/vim-stylus
|
stylus:wavded/vim-stylus
|
||||||
|
svg-indent:jasonshell/vim-svg-indent
|
||||||
|
svg:vim-scripts/svg.vim
|
||||||
swift:keith/swift.vim
|
swift:keith/swift.vim
|
||||||
sxhkd:baskerville/vim-sxhkdrc
|
sxhkd:baskerville/vim-sxhkdrc
|
||||||
systemd:wgwoods/vim-systemd-syntax
|
systemd:wgwoods/vim-systemd-syntax
|
||||||
@@ -281,6 +282,7 @@ PACKS="
|
|||||||
vifm:vifm/vifm.vim
|
vifm:vifm/vifm.vim
|
||||||
vm:lepture/vim-velocity
|
vm:lepture/vim-velocity
|
||||||
vue:posva/vim-vue
|
vue:posva/vim-vue
|
||||||
|
xdc:amal-khailtash/vim-xdc-syntax
|
||||||
xml:amadeus/vim-xml
|
xml:amadeus/vim-xml
|
||||||
xls:vim-scripts/XSLT-syntax
|
xls:vim-scripts/XSLT-syntax
|
||||||
yaml:stephpy/vim-yaml
|
yaml:stephpy/vim-yaml
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ syntax match jsDocTags contained "@\(alias\|api\|augments\|borrows\|cla
|
|||||||
" tags containing type and param
|
" tags containing type and param
|
||||||
syntax match jsDocTags contained "@\(arg\|argument\|cfg\|param\|property\|prop\|typedef\)\>" skipwhite nextgroup=jsDocType
|
syntax match jsDocTags contained "@\(arg\|argument\|cfg\|param\|property\|prop\|typedef\)\>" skipwhite nextgroup=jsDocType
|
||||||
" tags containing type but no param
|
" tags containing type but no param
|
||||||
syntax match jsDocTags contained "@\(callback\|define\|enum\|external\|implements\|this\|type\|return\|returns\)\>" skipwhite nextgroup=jsDocTypeNoParam
|
syntax match jsDocTags contained "@\(callback\|define\|enum\|external\|implements\|this\|type\|return\|returns\|yields\)\>" skipwhite nextgroup=jsDocTypeNoParam
|
||||||
" tags containing references
|
" tags containing references
|
||||||
syntax match jsDocTags contained "@\(lends\|see\|tutorial\)\>" skipwhite nextgroup=jsDocSeeTag
|
syntax match jsDocTags contained "@\(lends\|see\|tutorial\)\>" skipwhite nextgroup=jsDocSeeTag
|
||||||
" other tags (no extra syntax)
|
" other tags (no extra syntax)
|
||||||
|
|||||||
@@ -462,14 +462,6 @@ au BufNewFile,BufRead *.gradle set filetype=groovy
|
|||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'graphql') == -1
|
|
||||||
augroup filetypedetect
|
|
||||||
" graphql, from graphql.vim in jparise/vim-graphql
|
|
||||||
" vint: -ProhibitAutocmdWithNoGroup
|
|
||||||
au BufRead,BufNewFile *.graphql,*.graphqls,*.gql setfiletype graphql
|
|
||||||
augroup end
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'haml') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'haml') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" haml, from haml.vim in sheerun/vim-haml
|
" haml, from haml.vim in sheerun/vim-haml
|
||||||
@@ -669,28 +661,6 @@ autocmd BufNewFile,BufRead *.less setf less
|
|||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'liquid') == -1
|
|
||||||
augroup filetypedetect
|
|
||||||
" liquid, from liquid.vim in tpope/vim-liquid
|
|
||||||
" Liquid
|
|
||||||
au BufNewFile,BufRead *.liquid set ft=liquid
|
|
||||||
|
|
||||||
au BufNewFile,BufRead */_layouts/*.html,*/_includes/*.html set ft=liquid
|
|
||||||
au BufNewFile,BufRead *.html,*.xml,*.textile
|
|
||||||
\ if getline(1) == '---' | set ft=liquid | endif
|
|
||||||
au BufNewFile,BufRead *.markdown,*.mkd,*.mkdn,*.md
|
|
||||||
\ if getline(1) == '---' |
|
|
||||||
\ let b:liquid_subtype = 'markdown' |
|
|
||||||
\ set ft=liquid |
|
|
||||||
\ endif
|
|
||||||
|
|
||||||
" Set subtype for Shopify alternate templates
|
|
||||||
au BufNewFile,BufRead */templates/**.liquid,*/layout/**.liquid,*/snippets/**.liquid
|
|
||||||
\ let b:liquid_subtype = 'html' |
|
|
||||||
\ set ft=liquid |
|
|
||||||
augroup end
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'lilypond') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'lilypond') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" lilypond, from lilypond.vim in anowlcalledjosh/vim-lilypond
|
" lilypond, from lilypond.vim in anowlcalledjosh/vim-lilypond
|
||||||
@@ -714,6 +684,27 @@ autocmd BufNewFile,BufRead *Slakefile set filetype=ls
|
|||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'llvm') == -1
|
||||||
|
augroup filetypedetect
|
||||||
|
" llvm, from llvm-lit.vim in rhysd/vim-llvm
|
||||||
|
au BufRead,BufNewFile lit.*cfg set filetype=python
|
||||||
|
augroup end
|
||||||
|
endif
|
||||||
|
|
||||||
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'llvm') == -1
|
||||||
|
augroup filetypedetect
|
||||||
|
" llvm, from llvm.vim in rhysd/vim-llvm
|
||||||
|
au BufRead,BufNewFile *.ll set filetype=llvm
|
||||||
|
augroup end
|
||||||
|
endif
|
||||||
|
|
||||||
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'llvm') == -1
|
||||||
|
augroup filetypedetect
|
||||||
|
" llvm, from tablegen.vim in rhysd/vim-llvm
|
||||||
|
au BufRead,BufNewFile *.td set filetype=tablegen
|
||||||
|
augroup end
|
||||||
|
endif
|
||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'mako') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'mako') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" mako, from mako.vim in sophacles/vim-bundle-mako
|
" mako, from mako.vim in sophacles/vim-bundle-mako
|
||||||
@@ -745,6 +736,14 @@ au BufRead,BufNewFile *.{md,mdown,mkd,mkdn,markdown,mdwn}.{des3,des,bf,bfa,aes,i
|
|||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'mathematica') == -1
|
||||||
|
augroup filetypedetect
|
||||||
|
" mathematica, from mma.vim in voldikss/vim-mma
|
||||||
|
autocmd BufNewFile,BufRead *.wl set filetype=mma
|
||||||
|
autocmd BufNewFile,BufRead *.wls set filetype=mma
|
||||||
|
augroup end
|
||||||
|
endif
|
||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'mdx') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'mdx') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" mdx, from mdx.vim in jxnblk/vim-mdx-js
|
" mdx, from mdx.vim in jxnblk/vim-mdx-js
|
||||||
@@ -820,8 +819,8 @@ endif
|
|||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'ocaml') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'ocaml') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" ocaml, from jbuild.vim in rgrinberg/vim-ocaml
|
" ocaml, from dune.vim in rgrinberg/vim-ocaml
|
||||||
au BufRead,BufNewFile jbuild,dune,dune-project set ft=jbuild
|
au BufRead,BufNewFile jbuild,dune,dune-project set ft=dune
|
||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -927,9 +926,8 @@ endif
|
|||||||
|
|
||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'pgsql') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'pgsql') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" pgsql, from pgsql.vim in exu/pgsql.vim
|
" pgsql, from pgsql.vim in lifepillar/pgsql.vim
|
||||||
" postgreSQL
|
au BufNewFile,BufRead *.pgsql let b:sql_type_override='pgsql' | setfiletype sql
|
||||||
au BufNewFile,BufRead *.pgsql setf pgsql
|
|
||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -1056,7 +1054,7 @@ endif
|
|||||||
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'racket') == -1
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'racket') == -1
|
||||||
augroup filetypedetect
|
augroup filetypedetect
|
||||||
" racket, from racket.vim in wlangstroth/vim-racket
|
" racket, from racket.vim in wlangstroth/vim-racket
|
||||||
au BufRead,BufNewFile *.rkt,*.rktl set filetype=racket
|
au BufRead,BufNewFile *.rkt,*.rktl setf racket
|
||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@@ -1204,7 +1202,7 @@ if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'rust') == -1
|
|||||||
" vint: -ProhibitAutocmdWithNoGroup
|
" vint: -ProhibitAutocmdWithNoGroup
|
||||||
|
|
||||||
autocmd BufRead,BufNewFile *.rs setf rust
|
autocmd BufRead,BufNewFile *.rs setf rust
|
||||||
autocmd BufRead,BufNewFile Cargo.toml if &filetype == "" | set filetype=cfg | endif
|
autocmd BufRead,BufNewFile Cargo.toml setf FALLBACK cfg
|
||||||
|
|
||||||
" vim: set et sw=4 sts=4 ts=8:
|
" vim: set et sw=4 sts=4 ts=8:
|
||||||
augroup end
|
augroup end
|
||||||
@@ -1404,3 +1402,11 @@ au BufNewFile,BufRead *.vue,*.wpy setf vue
|
|||||||
augroup end
|
augroup end
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
if !exists('g:polyglot_disabled') || index(g:polyglot_disabled, 'xdc') == -1
|
||||||
|
augroup filetypedetect
|
||||||
|
" xdc, from xdc.vim in amal-khailtash/vim-xdc-syntax
|
||||||
|
" xdc
|
||||||
|
autocmd BufNewFile,BufRead *.xdc setfiletype xdc
|
||||||
|
augroup end
|
||||||
|
endif
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,10 @@ if !exists("b:eelixir_subtype")
|
|||||||
let b:eelixir_subtype = matchstr(&filetype,'^eex\.\zs\w\+')
|
let b:eelixir_subtype = matchstr(&filetype,'^eex\.\zs\w\+')
|
||||||
endif
|
endif
|
||||||
if b:eelixir_subtype == ''
|
if b:eelixir_subtype == ''
|
||||||
let b:eelixir_subtype = matchstr(substitute(expand("%:t"),'\c\%(\.eex\|\.eelixir\)\+$','',''),'\.\zs\w\+$')
|
let b:eelixir_subtype = matchstr(&filetype,'^leex\.\zs\w\+')
|
||||||
|
endif
|
||||||
|
if b:eelixir_subtype == ''
|
||||||
|
let b:eelixir_subtype = matchstr(substitute(expand("%:t"),'\c\%(\.eex\|\.leex\|\.eelixir\)\+$','',''),'\.\zs\w\+$')
|
||||||
endif
|
endif
|
||||||
if b:eelixir_subtype == 'ex'
|
if b:eelixir_subtype == 'ex'
|
||||||
let b:eelixir_subtype = 'elixir'
|
let b:eelixir_subtype = 'elixir'
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ let &l:path =
|
|||||||
\ &g:path
|
\ &g:path
|
||||||
\ ], ',')
|
\ ], ',')
|
||||||
setlocal includeexpr=elixir#util#get_filename(v:fname)
|
setlocal includeexpr=elixir#util#get_filename(v:fname)
|
||||||
setlocal suffixesadd=.ex,.exs,.eex,.erl,.xrl,.yrl,.hrl
|
setlocal suffixesadd=.ex,.exs,.eex,.leex,.erl,.xrl,.yrl,.hrl
|
||||||
|
|
||||||
let &l:define = 'def\(macro\|guard\|delegate\)\=p\='
|
let &l:define = 'def\(macro\|guard\|delegate\)\=p\='
|
||||||
|
|
||||||
|
|||||||
@@ -17,8 +17,10 @@ let b:did_ftplugin = 1
|
|||||||
|
|
||||||
setlocal comments=:# commentstring=#\ %s
|
setlocal comments=:# commentstring=#\ %s
|
||||||
setlocal nomodeline tabstop=8 formatoptions+=tl textwidth=72
|
setlocal nomodeline tabstop=8 formatoptions+=tl textwidth=72
|
||||||
setlocal formatoptions-=c formatoptions-=r formatoptions-=o formatoptions-=q
|
setlocal formatoptions-=c formatoptions-=r formatoptions-=o formatoptions-=q formatoptions+=n
|
||||||
let b:undo_ftplugin = 'setl modeline< tabstop< formatoptions< tw< com< cms<'
|
setlocal formatlistpat+=\\\|^\\s*[-*+]\\s\\+
|
||||||
|
|
||||||
|
let b:undo_ftplugin = 'setl modeline< tabstop< formatoptions< tw< com< cms< formatlistpat<'
|
||||||
|
|
||||||
if exists("g:no_gitcommit_commands") || v:version < 700
|
if exists("g:no_gitcommit_commands") || v:version < 700
|
||||||
finish
|
finish
|
||||||
|
|||||||
@@ -1,22 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'graphql') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Vim filetype plugin
|
|
||||||
" Language: GraphQL
|
|
||||||
" Maintainer: Jon Parise <jon@indelible.org>
|
|
||||||
|
|
||||||
if (exists('b:did_ftplugin'))
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
let b:did_ftplugin = 1
|
|
||||||
|
|
||||||
setlocal comments=:#
|
|
||||||
setlocal commentstring=#\ %s
|
|
||||||
setlocal formatoptions-=t
|
|
||||||
setlocal iskeyword+=$,@-@
|
|
||||||
setlocal softtabstop=2
|
|
||||||
setlocal shiftwidth=2
|
|
||||||
setlocal expandtab
|
|
||||||
|
|
||||||
let b:undo_ftplugin = 'setlocal com< cms< fo< isk< sts< sw< et<'
|
|
||||||
@@ -1,65 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'liquid') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Vim filetype plugin
|
|
||||||
" Language: Liquid
|
|
||||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
|
||||||
" Last Change: 2010 May 21
|
|
||||||
|
|
||||||
if exists('b:did_ftplugin')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('g:liquid_default_subtype')
|
|
||||||
let g:liquid_default_subtype = 'html'
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('b:liquid_subtype')
|
|
||||||
let s:lines = getline(1)."\n".getline(2)."\n".getline(3)."\n".getline(4)."\n".getline(5)."\n".getline("$")
|
|
||||||
let b:liquid_subtype = matchstr(s:lines,'liquid_subtype=\zs\w\+')
|
|
||||||
if b:liquid_subtype == ''
|
|
||||||
let b:liquid_subtype = matchstr(&filetype,'^liquid\.\zs\w\+')
|
|
||||||
endif
|
|
||||||
if b:liquid_subtype == ''
|
|
||||||
let b:liquid_subtype = matchstr(substitute(expand('%:t'),'\c\%(\.liquid\)\+$','',''),'\.\zs\w\+$')
|
|
||||||
endif
|
|
||||||
if b:liquid_subtype == ''
|
|
||||||
let b:liquid_subtype = g:liquid_default_subtype
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
if exists('b:liquid_subtype') && b:liquid_subtype != ''
|
|
||||||
exe 'runtime! ftplugin/'.b:liquid_subtype.'.vim ftplugin/'.b:liquid_subtype.'_*.vim ftplugin/'.b:liquid_subtype.'/*.vim'
|
|
||||||
else
|
|
||||||
runtime! ftplugin/html.vim ftplugin/html_*.vim ftplugin/html/*.vim
|
|
||||||
endif
|
|
||||||
let b:did_ftplugin = 1
|
|
||||||
|
|
||||||
if exists('b:undo_ftplugin')
|
|
||||||
let b:undo_ftplugin .= '|'
|
|
||||||
else
|
|
||||||
let b:undo_ftplugin = ''
|
|
||||||
endif
|
|
||||||
if exists('b:browsefilter')
|
|
||||||
let b:browsefilter = "\n".b:browsefilter
|
|
||||||
else
|
|
||||||
let b:browsefilter = ''
|
|
||||||
endif
|
|
||||||
if exists('b:match_words')
|
|
||||||
let b:match_words .= ','
|
|
||||||
elseif exists('loaded_matchit')
|
|
||||||
let b:match_words = ''
|
|
||||||
endif
|
|
||||||
|
|
||||||
if has('gui_win32')
|
|
||||||
let b:browsefilter="Liquid Files (*.liquid)\t*.liquid" . b:browsefilter
|
|
||||||
endif
|
|
||||||
|
|
||||||
if exists('loaded_matchit')
|
|
||||||
let b:match_words .= '\<\%(if\w*\|unless\|case\)\>:\<\%(elsif\|else\|when\)\>:\<end\%(if\w*\|unless\|case\)\>,\<\%(for\|tablerow\)\>:\%({%\s*\)\@<=empty\>:\<end\%(for\|tablerow\)\>,<\(capture\|comment\|highlight\)\>:\<end\1\>'
|
|
||||||
endif
|
|
||||||
|
|
||||||
setlocal commentstring={%\ comment\ %}%s{%\ endcomment\ %}
|
|
||||||
|
|
||||||
let b:undo_ftplugin .= 'setl cms< | unlet! b:browsefilter b:match_words'
|
|
||||||
16
ftplugin/llvm.vim
Normal file
16
ftplugin/llvm.vim
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim filetype plugin file
|
||||||
|
" Language: LLVM Assembly
|
||||||
|
" Maintainer: The LLVM team, http://llvm.org/
|
||||||
|
|
||||||
|
if exists("b:did_ftplugin")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let b:did_ftplugin = 1
|
||||||
|
|
||||||
|
setlocal softtabstop=2 shiftwidth=2
|
||||||
|
setlocal expandtab
|
||||||
|
setlocal comments+=:;
|
||||||
@@ -27,13 +27,13 @@ if exists("loaded_matchit") && !exists("b:match_words")
|
|||||||
let b:match_ignorecase = 0
|
let b:match_ignorecase = 0
|
||||||
|
|
||||||
let b:match_words =
|
let b:match_words =
|
||||||
\ '\<\%(if\|unless\|case\|while\|until\|for\|do\|class\|module\|def\|=\@<!begin\)\>=\@!' .
|
\ '{\|\<\%(if\|unless\|case\|while\|until\|for\|do\|class\|module\|def\|=\@<!begin\)\>=\@!' .
|
||||||
\ ':' .
|
\ ':' .
|
||||||
\ '\<\%(else\|elsif\|ensure\|when\|rescue\|break\|redo\|next\|retry\)\>' .
|
\ '\<\%(else\|elsif\|ensure\|when\|rescue\|break\|redo\|next\|retry\)\>' .
|
||||||
\ ':' .
|
\ ':' .
|
||||||
\ '\%(^\|[^.\:@$=]\)\@<=\<end\:\@!\>' .
|
\ '}\|\%(^\|[^.\:@$=]\)\@<=\<end\:\@!\>' .
|
||||||
\ ',^=begin\>:^=end\>,' .
|
\ ',^=begin\>:^=end\>,' .
|
||||||
\ ',{:},\[:\],(:)'
|
\ ',\[:\],(:)'
|
||||||
|
|
||||||
let b:match_skip =
|
let b:match_skip =
|
||||||
\ "synIDattr(synID(line('.'),col('.'),0),'name') =~ '" .
|
\ "synIDattr(synID(line('.'),col('.'),0),'name') =~ '" .
|
||||||
|
|||||||
16
ftplugin/tablegen.vim
Normal file
16
ftplugin/tablegen.vim
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim filetype plugin file
|
||||||
|
" Language: LLVM TableGen
|
||||||
|
" Maintainer: The LLVM team, http://llvm.org/
|
||||||
|
|
||||||
|
if exists("b:did_ftplugin")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let b:did_ftplugin = 1
|
||||||
|
|
||||||
|
setlocal matchpairs+=<:>
|
||||||
|
setlocal softtabstop=2 shiftwidth=2
|
||||||
|
setlocal expandtab
|
||||||
@@ -12,7 +12,7 @@ if exists("g:loaded_terraform") || v:version < 700 || &cp || !executable('terraf
|
|||||||
endif
|
endif
|
||||||
let g:loaded_terraform = 1
|
let g:loaded_terraform = 1
|
||||||
|
|
||||||
if !exists("g:terraform_fmt_on_save")
|
if !exists("g:terraform_fmt_on_save") || !filereadable(expand("%:p"))
|
||||||
let g:terraform_fmt_on_save = 0
|
let g:terraform_fmt_on_save = 0
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|||||||
@@ -1,81 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'graphql') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Vim indent file
|
|
||||||
" Language: GraphQL
|
|
||||||
" Maintainer: Jon Parise <jon@indelible.org>
|
|
||||||
|
|
||||||
if exists('b:did_indent')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
let b:did_indent = 1
|
|
||||||
|
|
||||||
setlocal autoindent
|
|
||||||
setlocal nocindent
|
|
||||||
setlocal nolisp
|
|
||||||
setlocal nosmartindent
|
|
||||||
|
|
||||||
setlocal indentexpr=GetGraphQLIndent()
|
|
||||||
setlocal indentkeys=0{,0},0),0[,0],0#,!^F,o,O
|
|
||||||
|
|
||||||
" If our indentation function already exists, we have nothing more to do.
|
|
||||||
if exists('*GetGraphQLIndent')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
let s:cpo_save = &cpoptions
|
|
||||||
set cpoptions&vim
|
|
||||||
|
|
||||||
" Check if the character at lnum:col is inside a string.
|
|
||||||
function s:InString(lnum, col)
|
|
||||||
return synIDattr(synID(a:lnum, a:col, 1), 'name') is# 'graphqlString'
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
function GetGraphQLIndent()
|
|
||||||
" If this is the first non-blank line, we have nothing more to do because
|
|
||||||
" all of our indentation rules are based on matching against earlier lines.
|
|
||||||
let l:prevlnum = prevnonblank(v:lnum - 1)
|
|
||||||
if l:prevlnum == 0
|
|
||||||
return 0
|
|
||||||
endif
|
|
||||||
|
|
||||||
let l:line = getline(v:lnum)
|
|
||||||
|
|
||||||
" If this line contains just a closing bracket, find its matching opening
|
|
||||||
" bracket and indent the closing backet to match.
|
|
||||||
let l:col = matchend(l:line, '^\s*[]})]')
|
|
||||||
if l:col > 0 && !s:InString(v:lnum, l:col)
|
|
||||||
let l:bracket = l:line[l:col - 1]
|
|
||||||
call cursor(v:lnum, l:col)
|
|
||||||
|
|
||||||
if l:bracket is# '}'
|
|
||||||
let l:matched = searchpair('{', '', '}', 'bW')
|
|
||||||
elseif l:bracket is# ']'
|
|
||||||
let l:matched = searchpair('\[', '', '\]', 'bW')
|
|
||||||
elseif l:bracket is# ')'
|
|
||||||
let l:matched = searchpair('(', '', ')', 'bW')
|
|
||||||
else
|
|
||||||
let l:matched = -1
|
|
||||||
endif
|
|
||||||
|
|
||||||
return l:matched > 0 ? indent(l:matched) : virtcol('.') - 1
|
|
||||||
endif
|
|
||||||
|
|
||||||
" If we're inside of a multiline string, continue with the same indentation.
|
|
||||||
if s:InString(v:lnum, matchend(l:line, '^\s*') + 1)
|
|
||||||
return indent(v:lnum)
|
|
||||||
endif
|
|
||||||
|
|
||||||
" If the previous line contained an opening bracket, and we are still in it,
|
|
||||||
" add indent depending on the bracket type.
|
|
||||||
if getline(l:prevlnum) =~# '[[{(]\s*$'
|
|
||||||
return indent(l:prevlnum) + shiftwidth()
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Default to the existing indentation level.
|
|
||||||
return indent(l:prevlnum)
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
let &cpoptions = s:cpo_save
|
|
||||||
unlet s:cpo_save
|
|
||||||
@@ -1,67 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'liquid') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Vim indent file
|
|
||||||
" Language: Liquid
|
|
||||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
|
||||||
" Last Change: 2010 May 21
|
|
||||||
|
|
||||||
if exists('b:did_indent')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
set indentexpr=
|
|
||||||
if exists('b:liquid_subtype')
|
|
||||||
exe 'runtime! indent/'.b:liquid_subtype.'.vim'
|
|
||||||
else
|
|
||||||
runtime! indent/html.vim
|
|
||||||
endif
|
|
||||||
unlet! b:did_indent
|
|
||||||
|
|
||||||
if &l:indentexpr == ''
|
|
||||||
if &l:cindent
|
|
||||||
let &l:indentexpr = 'cindent(v:lnum)'
|
|
||||||
else
|
|
||||||
let &l:indentexpr = 'indent(prevnonblank(v:lnum-1))'
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
let b:liquid_subtype_indentexpr = &l:indentexpr
|
|
||||||
|
|
||||||
let b:did_indent = 1
|
|
||||||
|
|
||||||
setlocal indentexpr=GetLiquidIndent()
|
|
||||||
setlocal indentkeys=o,O,*<Return>,<>>,{,},0),0],o,O,!^F,=end,=endif,=endunless,=endifchanged,=endcase,=endfor,=endtablerow,=endcapture,=else,=elsif,=when,=empty
|
|
||||||
|
|
||||||
" Only define the function once.
|
|
||||||
if exists('*GetLiquidIndent')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
function! s:count(string,pattern)
|
|
||||||
let string = substitute(a:string,'\C'.a:pattern,"\n",'g')
|
|
||||||
return strlen(substitute(string,"[^\n]",'','g'))
|
|
||||||
endfunction
|
|
||||||
|
|
||||||
function! GetLiquidIndent(...)
|
|
||||||
if a:0 && a:1 == '.'
|
|
||||||
let v:lnum = line('.')
|
|
||||||
elseif a:0 && a:1 =~ '^\d'
|
|
||||||
let v:lnum = a:1
|
|
||||||
endif
|
|
||||||
let vcol = col('.')
|
|
||||||
call cursor(v:lnum,1)
|
|
||||||
exe "let ind = ".b:liquid_subtype_indentexpr
|
|
||||||
let lnum = prevnonblank(v:lnum-1)
|
|
||||||
let line = getline(lnum)
|
|
||||||
let cline = getline(v:lnum)
|
|
||||||
let line = substitute(line,'\C^\%(\s*{%\s*end\w*\s*%}\)\+','','')
|
|
||||||
let line .= matchstr(cline,'\C^\%(\s*{%\s*end\w*\s*%}\)\+')
|
|
||||||
let cline = substitute(cline,'\C^\%(\s*{%\s*end\w*\s*%}\)\+','','')
|
|
||||||
let sw = exists('*shiftwidth') ? shiftwidth() : &sw
|
|
||||||
let ind += sw * s:count(line,'{%\s*\%(if\|elsif\|else\|unless\|ifchanged\|case\|when\|for\|empty\|tablerow\|capture\)\>')
|
|
||||||
let ind -= sw * s:count(line,'{%\s*end\%(if\|unless\|ifchanged\|case\|for\|tablerow\|capture\)\>')
|
|
||||||
let ind -= sw * s:count(cline,'{%\s*\%(elsif\|else\|when\|empty\)\>')
|
|
||||||
let ind -= sw * s:count(cline,'{%\s*end\w*$')
|
|
||||||
return ind
|
|
||||||
endfunction
|
|
||||||
76
indent/llvm.vim
Normal file
76
indent/llvm.vim
Normal file
@@ -0,0 +1,76 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim indent file
|
||||||
|
" Language: llvm
|
||||||
|
" Maintainer: The LLVM team, http://llvm.org/
|
||||||
|
" What this indent plugin currently does:
|
||||||
|
" - If no other rule matches copy indent from previous non-empty,
|
||||||
|
" non-commented line
|
||||||
|
" - On '}' align the same as the line containing the matching '{'
|
||||||
|
" - If previous line ends with ':' increase indentation
|
||||||
|
" - If the current line ends with ':' indent at the same level as the
|
||||||
|
" enclosing '{'/'}' block
|
||||||
|
" Stuff that would be nice to add:
|
||||||
|
" - Continue comments on next line
|
||||||
|
" - If there is an opening+unclosed parenthesis on previous line indent to that
|
||||||
|
if exists("b:did_indent")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let b:did_indent = 1
|
||||||
|
|
||||||
|
setlocal shiftwidth=2 expandtab
|
||||||
|
|
||||||
|
setlocal indentkeys=0{,0},<:>,!^F,o,O,e
|
||||||
|
setlocal indentexpr=GetLLVMIndent()
|
||||||
|
|
||||||
|
if exists("*GetLLVMIndent")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
function! FindOpenBrace(lnum)
|
||||||
|
call cursor(a:lnum, 1)
|
||||||
|
return searchpair('{', '', '}', 'bW')
|
||||||
|
endfun
|
||||||
|
|
||||||
|
function! GetLLVMIndent()
|
||||||
|
" On '}' align the same as the line containing the matching '{'
|
||||||
|
let thisline = getline(v:lnum)
|
||||||
|
if thisline =~ '^\s*}'
|
||||||
|
call cursor(v:lnum, 1)
|
||||||
|
silent normal %
|
||||||
|
let opening_lnum = line('.')
|
||||||
|
if opening_lnum != v:lnum
|
||||||
|
return indent(opening_lnum)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Indent labels the same as the current opening block
|
||||||
|
if thisline =~ ':\s*$'
|
||||||
|
let blockbegin = FindOpenBrace(v:lnum)
|
||||||
|
if blockbegin > 0
|
||||||
|
return indent(blockbegin)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Find a non-blank not-completely commented line above the current line.
|
||||||
|
let prev_lnum = prevnonblank(v:lnum - 1)
|
||||||
|
while prev_lnum > 0 && synIDattr(synID(prev_lnum, indent(prev_lnum)+1, 0), "name") =? "string\|comment"
|
||||||
|
let prev_lnum = prevnonblank(prev_lnum-1)
|
||||||
|
endwhile
|
||||||
|
" Hit the start of the file, use zero indent.
|
||||||
|
if prev_lnum == 0
|
||||||
|
return 0
|
||||||
|
endif
|
||||||
|
|
||||||
|
let ind = indent(prev_lnum)
|
||||||
|
let prevline = getline(prev_lnum)
|
||||||
|
|
||||||
|
" Add a 'shiftwidth' after lines that start a block or labels
|
||||||
|
if prevline =~ '{\s*$' || prevline =~ ':\s*$'
|
||||||
|
let ind = ind + &shiftwidth
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ind
|
||||||
|
endfunction
|
||||||
397
indent/pgsql.vim
Normal file
397
indent/pgsql.vim
Normal file
@@ -0,0 +1,397 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'pgsql') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim indent file
|
||||||
|
" Language: SQL
|
||||||
|
" Author: David Fishburn <dfishburn dot vim at gmail dot com>
|
||||||
|
" Maintainer: Lifepillar <lifepillar at lifepillar dot me>
|
||||||
|
|
||||||
|
" Notes:
|
||||||
|
" Adapted from Vim's default indentation for SQL.
|
||||||
|
"
|
||||||
|
|
||||||
|
" Only load this indent file when no other was loaded.
|
||||||
|
if exists("b:did_indent")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let b:did_indent = 1
|
||||||
|
let b:current_indent = "pgsql"
|
||||||
|
|
||||||
|
setlocal indentkeys-=0{
|
||||||
|
setlocal indentkeys-=0}
|
||||||
|
setlocal indentkeys-=:
|
||||||
|
setlocal indentkeys-=0#
|
||||||
|
setlocal indentkeys-=e
|
||||||
|
|
||||||
|
if has('patch-7.3.694') || (v:version == 703 && has('patch694'))
|
||||||
|
fun! s:shiftwidth()
|
||||||
|
return shiftwidth()
|
||||||
|
endf
|
||||||
|
|
||||||
|
else
|
||||||
|
fun! s:shiftwidth()
|
||||||
|
return &sw
|
||||||
|
endf
|
||||||
|
endif
|
||||||
|
|
||||||
|
" This indicates formatting should take place when one of these
|
||||||
|
" expressions is used. These expressions would normally be something
|
||||||
|
" you would type at the BEGINNING of a line
|
||||||
|
" SQL is generally case insensitive, so this files assumes that
|
||||||
|
" These keywords are something that would trigger an indent LEFT, not
|
||||||
|
" an indent right, since the SQLBlockStart is used for those keywords
|
||||||
|
setlocal indentkeys+==~end,=~else,=~elseif,=~elsif,0=~when,0=)
|
||||||
|
|
||||||
|
" GetSQLIndent is executed whenever one of the expressions
|
||||||
|
" in the indentkeys is typed
|
||||||
|
setlocal indentexpr=GetSQLIndent()
|
||||||
|
|
||||||
|
" Only define the functions once.
|
||||||
|
if exists("*GetSQLIndent")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let s:keepcpo= &cpo
|
||||||
|
set cpo&vim
|
||||||
|
|
||||||
|
" List of all the statements that start a new block.
|
||||||
|
" These are typically words that start a line.
|
||||||
|
" IS is excluded, since it is difficult to determine when the
|
||||||
|
" ending block is (especially for procedures/functions).
|
||||||
|
let s:SQLBlockStart = '^\s*\%('.
|
||||||
|
\ 'if\>.*\<then\|'.
|
||||||
|
\ 'then\|'.
|
||||||
|
\ 'else\|'.
|
||||||
|
\ 'elseif\>.*\<then\|'.
|
||||||
|
\ 'elsif\>.*\<then\|'.
|
||||||
|
\ 'while\>.*\<loop\|'.
|
||||||
|
\ 'for\>.*\<loop\|'.
|
||||||
|
\ 'foreach\>.*\<loop\|'.
|
||||||
|
\ 'loop\|'.
|
||||||
|
\ 'do\|'.
|
||||||
|
\ 'declare\|'.
|
||||||
|
\ 'begin\|'.
|
||||||
|
\ 'case\|'.
|
||||||
|
\ 'when\|'.
|
||||||
|
\ 'merge\|'.
|
||||||
|
\ 'exception'.
|
||||||
|
\ '\)\>'
|
||||||
|
let s:SQLBlockEnd = '^\s*\(end\)\>'
|
||||||
|
|
||||||
|
" The indent level is also based on unmatched parentheses
|
||||||
|
" If a line has an extra "(" increase the indent
|
||||||
|
" If a line has an extra ")" decrease the indent
|
||||||
|
function! s:CountUnbalancedParen( line, paren_to_check )
|
||||||
|
let l = a:line
|
||||||
|
let lp = substitute(l, '[^(]', '', 'g')
|
||||||
|
let l = a:line
|
||||||
|
let rp = substitute(l, '[^)]', '', 'g')
|
||||||
|
|
||||||
|
if a:paren_to_check =~ ')'
|
||||||
|
" echom 'CountUnbalancedParen ) returning: ' .
|
||||||
|
" \ (strlen(rp) - strlen(lp))
|
||||||
|
return (strlen(rp) - strlen(lp))
|
||||||
|
elseif a:paren_to_check =~ '('
|
||||||
|
" echom 'CountUnbalancedParen ( returning: ' .
|
||||||
|
" \ (strlen(lp) - strlen(rp))
|
||||||
|
return (strlen(lp) - strlen(rp))
|
||||||
|
else
|
||||||
|
" echom 'CountUnbalancedParen unknown paren to check: ' .
|
||||||
|
" \ a:paren_to_check
|
||||||
|
return 0
|
||||||
|
endif
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
" Unindent commands based on previous indent level
|
||||||
|
function! s:CheckToIgnoreRightParen( prev_lnum, num_levels )
|
||||||
|
let lnum = a:prev_lnum
|
||||||
|
let line = getline(lnum)
|
||||||
|
let ends = 0
|
||||||
|
let num_right_paren = a:num_levels
|
||||||
|
let ignore_paren = 0
|
||||||
|
let vircol = 1
|
||||||
|
|
||||||
|
while num_right_paren > 0
|
||||||
|
silent! exec 'norm! '.lnum."G\<bar>".vircol."\<bar>"
|
||||||
|
let right_paren = search( ')', 'W' )
|
||||||
|
if right_paren != lnum
|
||||||
|
" This should not happen since there should be at least
|
||||||
|
" num_right_paren matches for this line
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
let vircol = virtcol(".")
|
||||||
|
|
||||||
|
" if getline(".") =~ '^)'
|
||||||
|
let matching_paren = searchpair('(', '', ')', 'bW',
|
||||||
|
\ 's:IsColComment(line("."), col("."))')
|
||||||
|
|
||||||
|
if matching_paren < 1
|
||||||
|
" No match found
|
||||||
|
" echom 'CTIRP - no match found, ignoring'
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
|
||||||
|
if matching_paren == lnum
|
||||||
|
" This was not an unmatched parenthesis, start the search again
|
||||||
|
" again after this column
|
||||||
|
" echom 'CTIRP - same line match, ignoring'
|
||||||
|
continue
|
||||||
|
endif
|
||||||
|
|
||||||
|
" echom 'CTIRP - match: ' . line(".") . ' ' . getline(".")
|
||||||
|
|
||||||
|
if getline(matching_paren) =~? '\(if\|while\)\>'
|
||||||
|
" echom 'CTIRP - if/while ignored: ' . line(".") . ' ' . getline(".")
|
||||||
|
let ignore_paren = ignore_paren + 1
|
||||||
|
endif
|
||||||
|
|
||||||
|
" One match found, decrease and check for further matches
|
||||||
|
let num_right_paren = num_right_paren - 1
|
||||||
|
|
||||||
|
endwhile
|
||||||
|
|
||||||
|
" Fallback - just move back one
|
||||||
|
" return a:prev_indent - s:shiftwidth()
|
||||||
|
return ignore_paren
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
" Based on the keyword provided, loop through previous non empty
|
||||||
|
" non comment lines to find the statement that initiated the keyword.
|
||||||
|
" Return its indent level
|
||||||
|
" CASE ..
|
||||||
|
" WHEN ...
|
||||||
|
" Should return indent level of CASE
|
||||||
|
" EXCEPTION ..
|
||||||
|
" WHEN ...
|
||||||
|
" something;
|
||||||
|
" WHEN ...
|
||||||
|
" Should return indent level of exception.
|
||||||
|
function! s:GetStmtStarterIndent( keyword, curr_lnum )
|
||||||
|
let lnum = a:curr_lnum
|
||||||
|
|
||||||
|
" Default - reduce indent by 1
|
||||||
|
let ind = indent(a:curr_lnum) - s:shiftwidth()
|
||||||
|
|
||||||
|
if a:keyword =~? 'end'
|
||||||
|
exec 'normal! ^'
|
||||||
|
let stmts = '^\s*\%('.
|
||||||
|
\ '\<begin\>\|' .
|
||||||
|
\ '\%(\%(\<end\s\+\)\@<!\<loop\>\)\|' .
|
||||||
|
\ '\%(\%(\<end\s\+\)\@<!\<case\>\)\|' .
|
||||||
|
\ '\%(\%(\<end\s\+\)\@<!\<for\>\)\|' .
|
||||||
|
\ '\%(\%(\<end\s\+\)\@<!\<if\>\)'.
|
||||||
|
\ '\)'
|
||||||
|
let matching_lnum = searchpair(stmts, '', '\<end\>\zs', 'bW',
|
||||||
|
\ 's:IsColComment(line("."), col(".")) == 1')
|
||||||
|
exec 'normal! $'
|
||||||
|
if matching_lnum > 0 && matching_lnum < a:curr_lnum
|
||||||
|
let ind = indent(matching_lnum)
|
||||||
|
endif
|
||||||
|
elseif a:keyword =~? 'when'
|
||||||
|
exec 'normal! ^'
|
||||||
|
let matching_lnum = searchpair(
|
||||||
|
\ '\%(\<end\s\+\)\@<!\<case\>\|\<exception\>\|\<merge\>',
|
||||||
|
\ '',
|
||||||
|
\ '\%(\%(\<when\s\+others\>\)\|\%(\<end\s\+case\>\)\)',
|
||||||
|
\ 'bW',
|
||||||
|
\ 's:IsColComment(line("."), col(".")) == 1')
|
||||||
|
exec 'normal! $'
|
||||||
|
if matching_lnum > 0 && matching_lnum < a:curr_lnum
|
||||||
|
let ind = indent(matching_lnum)
|
||||||
|
else
|
||||||
|
let ind = indent(a:curr_lnum)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ind
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
" Check if the line is a comment
|
||||||
|
function! s:IsLineComment(lnum)
|
||||||
|
let rc = synIDattr(
|
||||||
|
\ synID(a:lnum,
|
||||||
|
\ match(getline(a:lnum), '\S')+1, 0)
|
||||||
|
\ , "name")
|
||||||
|
\ =~? "comment"
|
||||||
|
|
||||||
|
return rc
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
" Check if the column is a comment
|
||||||
|
function! s:IsColComment(lnum, cnum)
|
||||||
|
let rc = synIDattr(synID(a:lnum, a:cnum, 0), "name")
|
||||||
|
\ =~? "comment"
|
||||||
|
|
||||||
|
return rc
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
" Instead of returning a column position, return
|
||||||
|
" an appropriate value as a factor of shiftwidth.
|
||||||
|
function! s:ModuloIndent(ind)
|
||||||
|
let ind = a:ind
|
||||||
|
|
||||||
|
if ind > 0
|
||||||
|
let modulo = ind % s:shiftwidth()
|
||||||
|
|
||||||
|
if modulo > 0
|
||||||
|
let ind = ind - modulo
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
return ind
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
|
||||||
|
" Find correct indent of a new line based upon the previous line
|
||||||
|
function! GetSQLIndent()
|
||||||
|
let lnum = v:lnum
|
||||||
|
let ind = indent(lnum)
|
||||||
|
|
||||||
|
" If the current line is a comment, leave the indent as is
|
||||||
|
" Comment out this additional check since it affects the
|
||||||
|
" indenting of =, and will not reindent comments as it should
|
||||||
|
" if s:IsLineComment(lnum) == 1
|
||||||
|
" return ind
|
||||||
|
" endif
|
||||||
|
|
||||||
|
" Get previous non-blank line
|
||||||
|
let prevlnum = prevnonblank(lnum - 1)
|
||||||
|
if prevlnum <= 0
|
||||||
|
return ind
|
||||||
|
endif
|
||||||
|
|
||||||
|
if s:IsLineComment(prevlnum) == 1
|
||||||
|
if getline(v:lnum) =~ '^\s*\*'
|
||||||
|
let ind = s:ModuloIndent(indent(prevlnum))
|
||||||
|
return ind + 1
|
||||||
|
endif
|
||||||
|
" If the previous line is a comment, then return -1
|
||||||
|
" to tell Vim to use the formatoptions setting to determine
|
||||||
|
" the indent to use
|
||||||
|
" But only if the next line is blank. This would be true if
|
||||||
|
" the user is typing, but it would not be true if the user
|
||||||
|
" is reindenting the file
|
||||||
|
if getline(v:lnum) =~ '^\s*$'
|
||||||
|
return -1
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
" echom 'PREVIOUS INDENT: ' . indent(prevlnum) . ' LINE: ' . getline(prevlnum)
|
||||||
|
|
||||||
|
" This is the line you just hit return on, it is not the current line
|
||||||
|
" which is new and empty
|
||||||
|
" Based on this line, we can determine how much to indent the new
|
||||||
|
" line
|
||||||
|
|
||||||
|
" Get default indent (from prev. line)
|
||||||
|
let ind = indent(prevlnum)
|
||||||
|
let prevline = getline(prevlnum)
|
||||||
|
|
||||||
|
" Now check what's on the previous line to determine if the indent
|
||||||
|
" should be changed, for example IF, BEGIN, should increase the indent
|
||||||
|
" where END IF, END, should decrease the indent.
|
||||||
|
if prevline =~? s:SQLBlockStart
|
||||||
|
" Move indent in
|
||||||
|
let ind = ind + s:shiftwidth()
|
||||||
|
" echom 'prevl - SQLBlockStart - indent ' . ind . ' line: ' . prevline
|
||||||
|
elseif prevline =~ '[()]'
|
||||||
|
if prevline =~ '('
|
||||||
|
let num_unmatched_left = s:CountUnbalancedParen( prevline, '(' )
|
||||||
|
else
|
||||||
|
let num_unmatched_left = 0
|
||||||
|
endif
|
||||||
|
if prevline =~ ')'
|
||||||
|
let num_unmatched_right = s:CountUnbalancedParen( prevline, ')' )
|
||||||
|
else
|
||||||
|
let num_unmatched_right = 0
|
||||||
|
" let num_unmatched_right = s:CountUnbalancedParen( prevline, ')' )
|
||||||
|
endif
|
||||||
|
if num_unmatched_left > 0
|
||||||
|
" There is a open left parenthesis
|
||||||
|
" increase indent
|
||||||
|
let ind = ind + ( s:shiftwidth() * num_unmatched_left )
|
||||||
|
elseif num_unmatched_right > 0
|
||||||
|
" if it is an unbalanced parenthesis only unindent if
|
||||||
|
" it was part of a command (ie create table(..) )
|
||||||
|
" instead of part of an if (ie if (....) then) which should
|
||||||
|
" maintain the indent level
|
||||||
|
let ignore = s:CheckToIgnoreRightParen( prevlnum, num_unmatched_right )
|
||||||
|
" echom 'prevl - ) unbalanced - CTIRP - ignore: ' . ignore
|
||||||
|
|
||||||
|
if prevline =~ '^\s*)'
|
||||||
|
let ignore = ignore + 1
|
||||||
|
" echom 'prevl - begins ) unbalanced ignore: ' . ignore
|
||||||
|
endif
|
||||||
|
|
||||||
|
if (num_unmatched_right - ignore) > 0
|
||||||
|
let ind = ind - ( s:shiftwidth() * (num_unmatched_right - ignore) )
|
||||||
|
endif
|
||||||
|
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
" echom 'CURRENT INDENT: ' . ind . ' LINE: ' . getline(v:lnum)
|
||||||
|
|
||||||
|
" This is a new blank line since we just typed a carriage return
|
||||||
|
" Check current line; search for simplistic matching start-of-block
|
||||||
|
let line = getline(v:lnum)
|
||||||
|
|
||||||
|
if line =~? '^\s*els'
|
||||||
|
" Any line when you type else will automatically back up one
|
||||||
|
" ident level (ie else, elseif, elsif)
|
||||||
|
let ind = ind - s:shiftwidth()
|
||||||
|
" echom 'curr - else - indent ' . ind
|
||||||
|
elseif line =~? '^\s*end\>'
|
||||||
|
let ind = s:GetStmtStarterIndent('end', v:lnum)
|
||||||
|
" General case for end
|
||||||
|
" let ind = ind - s:shiftwidth()
|
||||||
|
" echom 'curr - end - indent ' . ind
|
||||||
|
elseif line =~? '^\s*when\>'
|
||||||
|
let ind = s:GetStmtStarterIndent('when', v:lnum)
|
||||||
|
" If the WHEN clause is used with a MERGE or EXCEPTION
|
||||||
|
" clause, do not change the indent level, since these
|
||||||
|
" statements do not have a corresponding END statement.
|
||||||
|
" if stmt_starter =~? 'case'
|
||||||
|
" let ind = ind - s:shiftwidth()
|
||||||
|
" endif
|
||||||
|
" elseif line =~ '^\s*)\s*;\?\s*$'
|
||||||
|
" elseif line =~ '^\s*)'
|
||||||
|
elseif line =~ '^\s*)'
|
||||||
|
let num_unmatched_right = s:CountUnbalancedParen( line, ')' )
|
||||||
|
let ignore = s:CheckToIgnoreRightParen( v:lnum, num_unmatched_right )
|
||||||
|
" If the line ends in a ), then reduce the indent
|
||||||
|
" This catches items like:
|
||||||
|
" CREATE TABLE T1(
|
||||||
|
" c1 int,
|
||||||
|
" c2 int
|
||||||
|
" );
|
||||||
|
" But we do not want to unindent a line like:
|
||||||
|
" IF ( c1 = 1
|
||||||
|
" AND c2 = 3 ) THEN
|
||||||
|
" let num_unmatched_right = s:CountUnbalancedParen( line, ')' )
|
||||||
|
" if num_unmatched_right > 0
|
||||||
|
" elseif strpart( line, strlen(line)-1, 1 ) =~ ')'
|
||||||
|
" let ind = ind - s:shiftwidth()
|
||||||
|
if line =~ '^\s*)'
|
||||||
|
" let ignore = ignore + 1
|
||||||
|
" echom 'curr - begins ) unbalanced ignore: ' . ignore
|
||||||
|
endif
|
||||||
|
|
||||||
|
if (num_unmatched_right - ignore) > 0
|
||||||
|
let ind = ind - ( s:shiftwidth() * (num_unmatched_right - ignore) )
|
||||||
|
endif
|
||||||
|
" endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
" echom 'final - indent ' . ind
|
||||||
|
return s:ModuloIndent(ind)
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
" Restore:
|
||||||
|
let &cpo= s:keepcpo
|
||||||
|
unlet s:keepcpo
|
||||||
|
" vim: ts=4 fdm=marker sw=4
|
||||||
93
indent/scss.vim
Normal file
93
indent/scss.vim
Normal file
@@ -0,0 +1,93 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'scss') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim indent file
|
||||||
|
" Language : SCSS (Sassy CSS)
|
||||||
|
" Maintainer : Daniel Hofstetter (daniel.hofstetter@42dh.com)
|
||||||
|
" URL : https://github.com/cakebaker/scss-syntax.vim
|
||||||
|
" Last Change : 2019-08-04
|
||||||
|
" Based on : css.vim by Nikolai Weibull, Oleg Zubchenko
|
||||||
|
" Modified by : ObserverOfTime
|
||||||
|
|
||||||
|
if exists('b:did_indent') | finish | endif
|
||||||
|
let b:did_indent = 1
|
||||||
|
|
||||||
|
setlocal indentexpr=GetSCSSIndent()
|
||||||
|
setlocal indentkeys=0{,0},0(,0),!^F,o,O
|
||||||
|
setlocal nosmartindent
|
||||||
|
|
||||||
|
let b:undo_indent = 'setl smartindent< indentkeys< indentexpr<'
|
||||||
|
|
||||||
|
if exists('*GetSCSSIndent') | finish | endif
|
||||||
|
let s:keepcpo= &cpoptions
|
||||||
|
set cpoptions&vim
|
||||||
|
|
||||||
|
function s:prevnonblanknoncomment(lnum)
|
||||||
|
let l:lnum = a:lnum
|
||||||
|
while l:lnum > 1
|
||||||
|
let l:lnum = prevnonblank(l:lnum)
|
||||||
|
let l:line = getline(l:lnum)
|
||||||
|
if l:line =~? '\*/'
|
||||||
|
while l:lnum > 1 && l:line !~? '/\*'
|
||||||
|
let l:lnum -= 1
|
||||||
|
endwhile
|
||||||
|
if l:line =~? '^\s*/\*'
|
||||||
|
let l:lnum -= 1
|
||||||
|
else
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
else
|
||||||
|
break
|
||||||
|
endif
|
||||||
|
endwhile
|
||||||
|
return l:lnum
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function s:count_chars(lnum, count_open, chars)
|
||||||
|
let l:n_open = 0
|
||||||
|
let l:n_close = 0
|
||||||
|
let l:line = getline(a:lnum)
|
||||||
|
let l:pattern = '['. a:chars .']'
|
||||||
|
let l:i = match(l:line, l:pattern)
|
||||||
|
let l:noi = 'scss\%(Comment\|StringQ\{1,2}\)'
|
||||||
|
while l:i != -1
|
||||||
|
if synIDattr(synID(a:lnum, l:i + 1, 0), 'name') !~? l:noi
|
||||||
|
if l:line[l:i] ==# a:chars[0]
|
||||||
|
let l:n_open += 1
|
||||||
|
elseif l:line[l:i] ==# a:chars[1]
|
||||||
|
if l:n_open > 0
|
||||||
|
let l:n_open -= 1
|
||||||
|
else
|
||||||
|
let l:n_close += 1
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
let l:i = match(l:line, l:pattern, l:i + 1)
|
||||||
|
endwhile
|
||||||
|
return a:count_open ? l:n_open : l:n_close
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function GetSCSSIndent()
|
||||||
|
let l:line = getline(v:lnum)
|
||||||
|
if l:line =~? '^\s*\*'
|
||||||
|
return cindent(v:lnum)
|
||||||
|
endif
|
||||||
|
|
||||||
|
let l:pnum = s:prevnonblanknoncomment(v:lnum - 1)
|
||||||
|
if l:pnum == 0
|
||||||
|
return 0
|
||||||
|
endif
|
||||||
|
|
||||||
|
return indent(l:pnum)
|
||||||
|
\ + s:count_chars(l:pnum, 1, '{}') * shiftwidth()
|
||||||
|
\ - s:count_chars(v:lnum, 0, '{}') * shiftwidth()
|
||||||
|
\ + s:count_chars(l:pnum, 1, '()') * shiftwidth()
|
||||||
|
\ - s:count_chars(v:lnum, 0, '()') * shiftwidth()
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
let &cpoptions = s:keepcpo
|
||||||
|
unlet s:keepcpo
|
||||||
|
|
||||||
|
" vim:set et ts=2 sw=2:
|
||||||
|
|
||||||
109
indent/svg.vim
Normal file
109
indent/svg.vim
Normal file
@@ -0,0 +1,109 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'svg-indent') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim indent file
|
||||||
|
"
|
||||||
|
" Language: svg
|
||||||
|
" Maintainer: Jason Shell <jason.shell.mail@gmail.com>
|
||||||
|
" Last Change: 2015 Sep 23
|
||||||
|
" Notes: 1) will be confused by unbalanced tags in comments
|
||||||
|
|
||||||
|
" Only load this indent file when no other was loaded.
|
||||||
|
if exists('b:did_indent')
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let b:did_indent = 1
|
||||||
|
let s:keepcpo= &cpo
|
||||||
|
set cpo&vim
|
||||||
|
|
||||||
|
" [-- local settings (must come before aborting the script) --]
|
||||||
|
setlocal indentexpr=SvgIndentGet(v:lnum,1)
|
||||||
|
setlocal indentkeys=o,O,*<Return>,<>>,<<>,/,{,}
|
||||||
|
|
||||||
|
if !exists('b:svg_indent_open')
|
||||||
|
let b:svg_indent_open = '.\{-}<\a'
|
||||||
|
" pre tag, e.g. <address>
|
||||||
|
" let b:svg_indent_open = '.\{-}<[/]\@!\(address\)\@!'
|
||||||
|
endif
|
||||||
|
|
||||||
|
if !exists('b:svg_indent_close')
|
||||||
|
let b:svg_indent_close = '.\{-}</'
|
||||||
|
" end pre tag, e.g. </address>
|
||||||
|
" let b:svg_indent_close = '.\{-}</\(address\)\@!'
|
||||||
|
endif
|
||||||
|
|
||||||
|
let &cpo = s:keepcpo
|
||||||
|
unlet s:keepcpo
|
||||||
|
|
||||||
|
" [-- finish, if the function already exists --]
|
||||||
|
if exists('*SvgIndentGet')
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
let s:keepcpo= &cpo
|
||||||
|
set cpo&vim
|
||||||
|
|
||||||
|
fun! <SID>SvgIndentWithPattern(line, pat)
|
||||||
|
let s = substitute('x'.a:line, a:pat, "\1", 'g')
|
||||||
|
return strlen(substitute(s, "[^\1].*$", '', ''))
|
||||||
|
endfun
|
||||||
|
|
||||||
|
" [-- check if it's svg --]
|
||||||
|
fun! <SID>SvgIndentSynCheck(lnum)
|
||||||
|
if '' != &syntax
|
||||||
|
let syn1 = synIDattr(synID(a:lnum, 1, 1), 'name')
|
||||||
|
let syn2 = synIDattr(synID(a:lnum, strlen(getline(a:lnum)) - 1, 1), 'name')
|
||||||
|
if '' != syn1 && syn1 !~ 'svg' && '' != syn2 && syn2 !~ 'svg'
|
||||||
|
" don't indent pure non-xml code
|
||||||
|
return 0
|
||||||
|
|
||||||
|
" elseif syn1 =~ '^xmlComment' && syn2 =~ '^xmlComment'
|
||||||
|
elseif syn1 =~ '^svgComment' && syn2 =~ '^svgComment'
|
||||||
|
" indent comments specially
|
||||||
|
return -1
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
return 1
|
||||||
|
endfun
|
||||||
|
|
||||||
|
" [-- return the sum of indents of a:lnum --]
|
||||||
|
fun! <SID>SvgIndentSum(lnum, style, add)
|
||||||
|
let line = getline(a:lnum)
|
||||||
|
if a:style == match(line, '^\s*</')
|
||||||
|
return (&sw *
|
||||||
|
\ (<SID>SvgIndentWithPattern(line, b:svg_indent_open)
|
||||||
|
\ - <SID>SvgIndentWithPattern(line, b:svg_indent_close)
|
||||||
|
\ - <SID>SvgIndentWithPattern(line, '.\{-}/>'))) + a:add
|
||||||
|
else
|
||||||
|
return a:add
|
||||||
|
endif
|
||||||
|
endfun
|
||||||
|
|
||||||
|
fun! SvgIndentGet(lnum, use_syntax_check)
|
||||||
|
" Find a non-empty line above the current line.
|
||||||
|
let lnum = prevnonblank(a:lnum - 1)
|
||||||
|
|
||||||
|
" Hit the start of the file, use zero indent.
|
||||||
|
if lnum == 0
|
||||||
|
return 0
|
||||||
|
endif
|
||||||
|
|
||||||
|
if a:use_syntax_check
|
||||||
|
let check_lnum = <SID>SvgIndentSynCheck(lnum)
|
||||||
|
let check_alnum = <SID>SvgIndentSynCheck(a:lnum)
|
||||||
|
if 0 == check_lnum || 0 == check_alnum
|
||||||
|
return indent(a:lnum)
|
||||||
|
elseif -1 == check_lnum || -1 == check_alnum
|
||||||
|
return -1
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
let ind = <SID>SvgIndentSum(lnum, -1, indent(lnum))
|
||||||
|
let ind = <SID>SvgIndentSum(a:lnum, 0, ind)
|
||||||
|
|
||||||
|
return ind
|
||||||
|
endfun
|
||||||
|
|
||||||
|
let &cpo = s:keepcpo
|
||||||
|
unlet s:keepcpo
|
||||||
@@ -36,6 +36,7 @@ syn region bladeComment matchgroup=bladeDelimiter start="{{--" end="--}}" c
|
|||||||
syn keyword bladeKeyword @if @elseif @foreach @forelse @for @while @can @cannot @elsecan @elsecannot @include
|
syn keyword bladeKeyword @if @elseif @foreach @forelse @for @while @can @cannot @elsecan @elsecannot @include
|
||||||
\ @includeIf @each @inject @extends @section @stack @push @unless @yield @parent @hasSection @break @continue
|
\ @includeIf @each @inject @extends @section @stack @push @unless @yield @parent @hasSection @break @continue
|
||||||
\ @unset @lang @choice @component @slot @prepend @json @isset @auth @guest @switch @case @includeFirst @empty
|
\ @unset @lang @choice @component @slot @prepend @json @isset @auth @guest @switch @case @includeFirst @empty
|
||||||
|
\ @includeWhen
|
||||||
\ nextgroup=bladePhpParenBlock skipwhite containedin=ALLBUT,@bladeExempt
|
\ nextgroup=bladePhpParenBlock skipwhite containedin=ALLBUT,@bladeExempt
|
||||||
|
|
||||||
syn keyword bladeKeyword @else @endif @endunless @endfor @endforeach @endforelse @endwhile @endcan
|
syn keyword bladeKeyword @else @endif @endunless @endfor @endforeach @endforelse @endwhile @endcan
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ else
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
syn keyword carpSyntax def defn let do if while ref address set! the
|
syn keyword carpSyntax def defn let do if while ref address set! the
|
||||||
syn keyword carpSyntax defmacro defdynamic quote cons list array fn
|
syn keyword carpSyntax defmacro defdynamic defndynamic quote cons list array fn
|
||||||
syn keyword carpSyntax expand deftype register system-include register-type
|
syn keyword carpSyntax expand deftype register system-include register-type
|
||||||
syn keyword carpSyntax defmodule copy use module defalias definterface eval
|
syn keyword carpSyntax defmodule copy use module defalias definterface eval
|
||||||
syn keyword carpSyntax expand instantiate type info help quit env build run
|
syn keyword carpSyntax expand instantiate type info help quit env build run
|
||||||
|
|||||||
114
syntax/cmake.vim
114
syntax/cmake.vim
@@ -4,14 +4,14 @@ endif
|
|||||||
|
|
||||||
" Vim syntax file
|
" Vim syntax file
|
||||||
" Program: CMake - Cross-Platform Makefile Generator
|
" Program: CMake - Cross-Platform Makefile Generator
|
||||||
" Version: cmake version 3.13.20181220-g0495c
|
" Version: cmake version 3.14.20190402-g56ae2
|
||||||
" Language: CMake
|
" Language: CMake
|
||||||
" Author: Andy Cedilnik <andy.cedilnik@kitware.com>,
|
" Author: Andy Cedilnik <andy.cedilnik@kitware.com>,
|
||||||
" Nicholas Hutchinson <nshutchinson@gmail.com>,
|
" Nicholas Hutchinson <nshutchinson@gmail.com>,
|
||||||
" Patrick Boettcher <patrick.boettcher@posteo.de>
|
" Patrick Boettcher <patrick.boettcher@posteo.de>
|
||||||
" Maintainer: Dimitri Merejkowsky <d.merej@gmail.com>
|
" Maintainer: Dimitri Merejkowsky <d.merej@gmail.com>
|
||||||
" Former Maintainer: Karthik Krishnan <karthik.krishnan@kitware.com>
|
" Former Maintainer: Karthik Krishnan <karthik.krishnan@kitware.com>
|
||||||
" Last Change: 2018 Dec 20
|
" Last Change: 2019 Apr 15
|
||||||
"
|
"
|
||||||
" Licence: The CMake license applies to this file. See
|
" Licence: The CMake license applies to this file. See
|
||||||
" https://cmake.org/licensing
|
" https://cmake.org/licensing
|
||||||
@@ -35,7 +35,7 @@ syn region cmakeGeneratorExpression start="$<" end=">" contained oneline contain
|
|||||||
|
|
||||||
syn region cmakeString start='"' end='"' contained contains=cmakeTodo,cmakeVariableValue,cmakeEscaped
|
syn region cmakeString start='"' end='"' contained contains=cmakeTodo,cmakeVariableValue,cmakeEscaped
|
||||||
|
|
||||||
syn region cmakeVariableValue start="${" end="}" contained oneline contains=cmakeVariable,cmakeTodo
|
syn region cmakeVariableValue start="${" end="}" contained oneline contains=cmakeVariable,cmakeTodo,cmakeVariableValue
|
||||||
|
|
||||||
syn region cmakeEnvironment start="$ENV{" end="}" contained oneline contains=cmakeTodo
|
syn region cmakeEnvironment start="$ENV{" end="}" contained oneline contains=cmakeTodo
|
||||||
|
|
||||||
@@ -79,14 +79,17 @@ syn keyword cmakeProperty contained
|
|||||||
\ AUTOMOC
|
\ AUTOMOC
|
||||||
\ AUTOMOC_COMPILER_PREDEFINES
|
\ AUTOMOC_COMPILER_PREDEFINES
|
||||||
\ AUTOMOC_DEPEND_FILTERS
|
\ AUTOMOC_DEPEND_FILTERS
|
||||||
|
\ AUTOMOC_EXECUTABLE
|
||||||
\ AUTOMOC_MACRO_NAMES
|
\ AUTOMOC_MACRO_NAMES
|
||||||
\ AUTOMOC_MOC_OPTIONS
|
\ AUTOMOC_MOC_OPTIONS
|
||||||
\ AUTOMOC_SOURCE_GROUP
|
\ AUTOMOC_SOURCE_GROUP
|
||||||
\ AUTOMOC_TARGETS_FOLDER
|
\ AUTOMOC_TARGETS_FOLDER
|
||||||
\ AUTORCC
|
\ AUTORCC
|
||||||
|
\ AUTORCC_EXECUTABLE
|
||||||
\ AUTORCC_OPTIONS
|
\ AUTORCC_OPTIONS
|
||||||
\ AUTORCC_SOURCE_GROUP
|
\ AUTORCC_SOURCE_GROUP
|
||||||
\ AUTOUIC
|
\ AUTOUIC
|
||||||
|
\ AUTOUIC_EXECUTABLE
|
||||||
\ AUTOUIC_OPTIONS
|
\ AUTOUIC_OPTIONS
|
||||||
\ AUTOUIC_SEARCH_PATHS
|
\ AUTOUIC_SEARCH_PATHS
|
||||||
\ BINARY_DIR
|
\ BINARY_DIR
|
||||||
@@ -102,6 +105,7 @@ syn keyword cmakeProperty contained
|
|||||||
\ CMAKE_CONFIGURE_DEPENDS
|
\ CMAKE_CONFIGURE_DEPENDS
|
||||||
\ CMAKE_CXX_KNOWN_FEATURES
|
\ CMAKE_CXX_KNOWN_FEATURES
|
||||||
\ CMAKE_C_KNOWN_FEATURES
|
\ CMAKE_C_KNOWN_FEATURES
|
||||||
|
\ CMAKE_ROLE
|
||||||
\ COMMON_LANGUAGE_RUNTIME
|
\ COMMON_LANGUAGE_RUNTIME
|
||||||
\ COMPATIBLE_INTERFACE_BOOL
|
\ COMPATIBLE_INTERFACE_BOOL
|
||||||
\ COMPATIBLE_INTERFACE_NUMBER_MAX
|
\ COMPATIBLE_INTERFACE_NUMBER_MAX
|
||||||
@@ -171,6 +175,8 @@ syn keyword cmakeProperty contained
|
|||||||
\ GENERATED
|
\ GENERATED
|
||||||
\ GENERATOR_FILE_NAME
|
\ GENERATOR_FILE_NAME
|
||||||
\ GENERATOR_IS_MULTI_CONFIG
|
\ GENERATOR_IS_MULTI_CONFIG
|
||||||
|
\ GHS_INTEGRITY_APP
|
||||||
|
\ GHS_NO_SOURCE_GROUP_FILE
|
||||||
\ GLOBAL_DEPENDS_DEBUG_MODE
|
\ GLOBAL_DEPENDS_DEBUG_MODE
|
||||||
\ GLOBAL_DEPENDS_NO_CYCLES
|
\ GLOBAL_DEPENDS_NO_CYCLES
|
||||||
\ GNUtoMS
|
\ GNUtoMS
|
||||||
@@ -328,6 +334,7 @@ syn keyword cmakeProperty contained
|
|||||||
\ VS_IOT_STARTUP_TASK
|
\ VS_IOT_STARTUP_TASK
|
||||||
\ VS_KEYWORD
|
\ VS_KEYWORD
|
||||||
\ VS_MOBILE_EXTENSIONS_VERSION
|
\ VS_MOBILE_EXTENSIONS_VERSION
|
||||||
|
\ VS_NO_SOLUTION_DEPLOY
|
||||||
\ VS_RESOURCE_GENERATOR
|
\ VS_RESOURCE_GENERATOR
|
||||||
\ VS_SCC_AUXPATH
|
\ VS_SCC_AUXPATH
|
||||||
\ VS_SCC_LOCALPATH
|
\ VS_SCC_LOCALPATH
|
||||||
@@ -359,11 +366,13 @@ syn keyword cmakeProperty contained
|
|||||||
\ XCODE_EMIT_EFFECTIVE_PLATFORM_NAME
|
\ XCODE_EMIT_EFFECTIVE_PLATFORM_NAME
|
||||||
\ XCODE_EXPLICIT_FILE_TYPE
|
\ XCODE_EXPLICIT_FILE_TYPE
|
||||||
\ XCODE_FILE_ATTRIBUTES
|
\ XCODE_FILE_ATTRIBUTES
|
||||||
|
\ XCODE_GENERATE_SCHEME
|
||||||
\ XCODE_LAST_KNOWN_FILE_TYPE
|
\ XCODE_LAST_KNOWN_FILE_TYPE
|
||||||
\ XCODE_PRODUCT_TYPE
|
\ XCODE_PRODUCT_TYPE
|
||||||
\ XCODE_SCHEME_ADDRESS_SANITIZER
|
\ XCODE_SCHEME_ADDRESS_SANITIZER
|
||||||
\ XCODE_SCHEME_ADDRESS_SANITIZER_USE_AFTER_RETURN
|
\ XCODE_SCHEME_ADDRESS_SANITIZER_USE_AFTER_RETURN
|
||||||
\ XCODE_SCHEME_ARGUMENTS
|
\ XCODE_SCHEME_ARGUMENTS
|
||||||
|
\ XCODE_SCHEME_DEBUG_AS_ROOT
|
||||||
\ XCODE_SCHEME_DISABLE_MAIN_THREAD_CHECKER
|
\ XCODE_SCHEME_DISABLE_MAIN_THREAD_CHECKER
|
||||||
\ XCODE_SCHEME_DYNAMIC_LIBRARY_LOADS
|
\ XCODE_SCHEME_DYNAMIC_LIBRARY_LOADS
|
||||||
\ XCODE_SCHEME_DYNAMIC_LINKER_API_USAGE
|
\ XCODE_SCHEME_DYNAMIC_LINKER_API_USAGE
|
||||||
@@ -455,10 +464,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_ASM_FLAGS_RELEASE_INIT
|
\ CMAKE_ASM_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_ASM_FLAGS_RELWITHDEBINFO
|
\ CMAKE_ASM_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_ASM_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_ASM_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_ASM_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_ASM_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_ASM_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_ASM_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_ASM_IGNORE_EXTENSIONS
|
\ CMAKE_ASM_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_ASM_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_ASM_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_ASM_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_ASM_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -509,10 +514,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_ASM_MASM_FLAGS_RELEASE_INIT
|
\ CMAKE_ASM_MASM_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_ASM_MASM_FLAGS_RELWITHDEBINFO
|
\ CMAKE_ASM_MASM_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_ASM_MASM_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_ASM_MASM_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_ASM_MASM_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_ASM_MASM_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_ASM_MASM_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_ASM_MASM_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_ASM_MASM_IGNORE_EXTENSIONS
|
\ CMAKE_ASM_MASM_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_ASM_MASM_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_ASM_MASM_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_ASM_MASM_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_ASM_MASM_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -572,10 +573,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_ASM_NASM_FLAGS_RELEASE_INIT
|
\ CMAKE_ASM_NASM_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_ASM_NASM_FLAGS_RELWITHDEBINFO
|
\ CMAKE_ASM_NASM_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_ASM_NASM_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_ASM_NASM_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_ASM_NASM_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_ASM_NASM_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_ASM_NASM_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_ASM_NASM_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_ASM_NASM_IGNORE_EXTENSIONS
|
\ CMAKE_ASM_NASM_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_ASM_NASM_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_ASM_NASM_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_ASM_NASM_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_ASM_NASM_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -687,10 +684,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_CSharp_FLAGS_RELEASE_INIT
|
\ CMAKE_CSharp_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_CSharp_FLAGS_RELWITHDEBINFO
|
\ CMAKE_CSharp_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_CSharp_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_CSharp_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_CSharp_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_CSharp_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_CSharp_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_CSharp_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_CSharp_IGNORE_EXTENSIONS
|
\ CMAKE_CSharp_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_CSharp_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_CSharp_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_CSharp_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_CSharp_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -752,10 +745,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_CUDA_FLAGS_RELEASE_INIT
|
\ CMAKE_CUDA_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_CUDA_FLAGS_RELWITHDEBINFO
|
\ CMAKE_CUDA_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_CUDA_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_CUDA_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_CUDA_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_CUDA_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_CUDA_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_CUDA_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_CUDA_HOST_COMPILER
|
\ CMAKE_CUDA_HOST_COMPILER
|
||||||
\ CMAKE_CUDA_IGNORE_EXTENSIONS
|
\ CMAKE_CUDA_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_CUDA_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_CUDA_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
@@ -827,10 +816,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_CXX_FLAGS_RELEASE_INIT
|
\ CMAKE_CXX_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_CXX_FLAGS_RELWITHDEBINFO
|
\ CMAKE_CXX_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_CXX_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_CXX_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_CXX_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_CXX_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_CXX_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_CXX_IGNORE_EXTENSIONS
|
\ CMAKE_CXX_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_CXX_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_CXX_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -893,10 +878,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_C_FLAGS_RELEASE_INIT
|
\ CMAKE_C_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_C_FLAGS_RELWITHDEBINFO
|
\ CMAKE_C_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_C_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_C_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_C_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_C_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_C_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_C_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_C_IGNORE_EXTENSIONS
|
\ CMAKE_C_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_C_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_C_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_C_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -940,6 +921,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_EXE_LINKER_FLAGS_INIT
|
\ CMAKE_EXE_LINKER_FLAGS_INIT
|
||||||
\ CMAKE_EXPORT_COMPILE_COMMANDS
|
\ CMAKE_EXPORT_COMPILE_COMMANDS
|
||||||
\ CMAKE_EXPORT_NO_PACKAGE_REGISTRY
|
\ CMAKE_EXPORT_NO_PACKAGE_REGISTRY
|
||||||
|
\ CMAKE_EXPORT_PACKAGE_REGISTRY
|
||||||
\ CMAKE_EXTRA_GENERATOR
|
\ CMAKE_EXTRA_GENERATOR
|
||||||
\ CMAKE_EXTRA_SHARED_LIBRARY_SUFFIXES
|
\ CMAKE_EXTRA_SHARED_LIBRARY_SUFFIXES
|
||||||
\ CMAKE_FIND_APPBUNDLE
|
\ CMAKE_FIND_APPBUNDLE
|
||||||
@@ -951,6 +933,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_FIND_PACKAGE_NAME
|
\ CMAKE_FIND_PACKAGE_NAME
|
||||||
\ CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY
|
\ CMAKE_FIND_PACKAGE_NO_PACKAGE_REGISTRY
|
||||||
\ CMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY
|
\ CMAKE_FIND_PACKAGE_NO_SYSTEM_PACKAGE_REGISTRY
|
||||||
|
\ CMAKE_FIND_PACKAGE_RESOLVE_SYMLINKS
|
||||||
\ CMAKE_FIND_PACKAGE_SORT_DIRECTION
|
\ CMAKE_FIND_PACKAGE_SORT_DIRECTION
|
||||||
\ CMAKE_FIND_PACKAGE_SORT_ORDER
|
\ CMAKE_FIND_PACKAGE_SORT_ORDER
|
||||||
\ CMAKE_FIND_PACKAGE_WARN_NO_MODULE
|
\ CMAKE_FIND_PACKAGE_WARN_NO_MODULE
|
||||||
@@ -999,10 +982,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_Fortran_FLAGS_RELWITHDEBINFO
|
\ CMAKE_Fortran_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_Fortran_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_Fortran_FORMAT
|
\ CMAKE_Fortran_FORMAT
|
||||||
\ CMAKE_Fortran_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_Fortran_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_Fortran_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_Fortran_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_Fortran_IGNORE_EXTENSIONS
|
\ CMAKE_Fortran_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_Fortran_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_Fortran_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_Fortran_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_Fortran_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -1033,6 +1012,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_GENERATOR_INSTANCE
|
\ CMAKE_GENERATOR_INSTANCE
|
||||||
\ CMAKE_GENERATOR_PLATFORM
|
\ CMAKE_GENERATOR_PLATFORM
|
||||||
\ CMAKE_GENERATOR_TOOLSET
|
\ CMAKE_GENERATOR_TOOLSET
|
||||||
|
\ CMAKE_GHS_NO_SOURCE_GROUP_FILE
|
||||||
\ CMAKE_GLOBAL_AUTOGEN_TARGET
|
\ CMAKE_GLOBAL_AUTOGEN_TARGET
|
||||||
\ CMAKE_GLOBAL_AUTOGEN_TARGET_NAME
|
\ CMAKE_GLOBAL_AUTOGEN_TARGET_NAME
|
||||||
\ CMAKE_GLOBAL_AUTORCC_TARGET
|
\ CMAKE_GLOBAL_AUTORCC_TARGET
|
||||||
@@ -1106,10 +1086,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_Java_FLAGS_RELEASE_INIT
|
\ CMAKE_Java_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_Java_FLAGS_RELWITHDEBINFO
|
\ CMAKE_Java_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_Java_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_Java_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_Java_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_Java_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_Java_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_Java_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_Java_IGNORE_EXTENSIONS
|
\ CMAKE_Java_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_Java_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_Java_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_Java_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_Java_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -1152,6 +1128,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_MAJOR_VERSION
|
\ CMAKE_MAJOR_VERSION
|
||||||
\ CMAKE_MAKE_PROGRAM
|
\ CMAKE_MAKE_PROGRAM
|
||||||
\ CMAKE_MATCH_COUNT
|
\ CMAKE_MATCH_COUNT
|
||||||
|
\ CMAKE_MAXIMUM_RECURSION_DEPTH
|
||||||
\ CMAKE_MFC_FLAG
|
\ CMAKE_MFC_FLAG
|
||||||
\ CMAKE_MINIMUM_REQUIRED_VERSION
|
\ CMAKE_MINIMUM_REQUIRED_VERSION
|
||||||
\ CMAKE_MINOR_VERSION
|
\ CMAKE_MINOR_VERSION
|
||||||
@@ -1177,6 +1154,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_PROGRAM_PATH
|
\ CMAKE_PROGRAM_PATH
|
||||||
\ CMAKE_PROJECT_DESCRIPTION
|
\ CMAKE_PROJECT_DESCRIPTION
|
||||||
\ CMAKE_PROJECT_HOMEPAGE_URL
|
\ CMAKE_PROJECT_HOMEPAGE_URL
|
||||||
|
\ CMAKE_PROJECT_INCLUDE
|
||||||
\ CMAKE_PROJECT_NAME
|
\ CMAKE_PROJECT_NAME
|
||||||
\ CMAKE_PROJECT_VERSION
|
\ CMAKE_PROJECT_VERSION
|
||||||
\ CMAKE_PROJECT_VERSION_MAJOR
|
\ CMAKE_PROJECT_VERSION_MAJOR
|
||||||
@@ -1221,10 +1199,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_RC_FLAGS_RELEASE_INIT
|
\ CMAKE_RC_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_RC_FLAGS_RELWITHDEBINFO
|
\ CMAKE_RC_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_RC_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_RC_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_RC_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_RC_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_RC_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_RC_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_RC_IGNORE_EXTENSIONS
|
\ CMAKE_RC_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_RC_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_RC_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_RC_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_RC_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -1323,10 +1297,6 @@ syn keyword cmakeVariable contained
|
|||||||
\ CMAKE_Swift_FLAGS_RELEASE_INIT
|
\ CMAKE_Swift_FLAGS_RELEASE_INIT
|
||||||
\ CMAKE_Swift_FLAGS_RELWITHDEBINFO
|
\ CMAKE_Swift_FLAGS_RELWITHDEBINFO
|
||||||
\ CMAKE_Swift_FLAGS_RELWITHDEBINFO_INIT
|
\ CMAKE_Swift_FLAGS_RELWITHDEBINFO_INIT
|
||||||
\ CMAKE_Swift_GHS_KERNEL_FLAGS_DEBUG
|
|
||||||
\ CMAKE_Swift_GHS_KERNEL_FLAGS_MINSIZEREL
|
|
||||||
\ CMAKE_Swift_GHS_KERNEL_FLAGS_RELEASE
|
|
||||||
\ CMAKE_Swift_GHS_KERNEL_FLAGS_RELWITHDEBINFO
|
|
||||||
\ CMAKE_Swift_IGNORE_EXTENSIONS
|
\ CMAKE_Swift_IGNORE_EXTENSIONS
|
||||||
\ CMAKE_Swift_IMPLICIT_INCLUDE_DIRECTORIES
|
\ CMAKE_Swift_IMPLICIT_INCLUDE_DIRECTORIES
|
||||||
\ CMAKE_Swift_IMPLICIT_LINK_DIRECTORIES
|
\ CMAKE_Swift_IMPLICIT_LINK_DIRECTORIES
|
||||||
@@ -1449,7 +1419,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CTEST_CUSTOM_POST_TEST
|
\ CTEST_CUSTOM_POST_TEST
|
||||||
\ CTEST_CUSTOM_PRE_MEMCHECK
|
\ CTEST_CUSTOM_PRE_MEMCHECK
|
||||||
\ CTEST_CUSTOM_PRE_TEST
|
\ CTEST_CUSTOM_PRE_TEST
|
||||||
\ CTEST_CUSTOM_TEST_IGNORE
|
\ CTEST_CUSTOM_TESTS_IGNORE
|
||||||
\ CTEST_CUSTOM_WARNING_EXCEPTION
|
\ CTEST_CUSTOM_WARNING_EXCEPTION
|
||||||
\ CTEST_CUSTOM_WARNING_MATCH
|
\ CTEST_CUSTOM_WARNING_MATCH
|
||||||
\ CTEST_CVS_CHECKOUT
|
\ CTEST_CVS_CHECKOUT
|
||||||
@@ -1483,6 +1453,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ CTEST_SCP_COMMAND
|
\ CTEST_SCP_COMMAND
|
||||||
\ CTEST_SITE
|
\ CTEST_SITE
|
||||||
\ CTEST_SOURCE_DIRECTORY
|
\ CTEST_SOURCE_DIRECTORY
|
||||||
|
\ CTEST_SUBMIT_URL
|
||||||
\ CTEST_SVN_COMMAND
|
\ CTEST_SVN_COMMAND
|
||||||
\ CTEST_SVN_OPTIONS
|
\ CTEST_SVN_OPTIONS
|
||||||
\ CTEST_SVN_UPDATE_OPTIONS
|
\ CTEST_SVN_UPDATE_OPTIONS
|
||||||
@@ -1497,6 +1468,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ ENV
|
\ ENV
|
||||||
\ EXECUTABLE_OUTPUT_PATH
|
\ EXECUTABLE_OUTPUT_PATH
|
||||||
\ GHS-MULTI
|
\ GHS-MULTI
|
||||||
|
\ IOS
|
||||||
\ LIBRARY_OUTPUT_PATH
|
\ LIBRARY_OUTPUT_PATH
|
||||||
\ MINGW
|
\ MINGW
|
||||||
\ MSVC
|
\ MSVC
|
||||||
@@ -1512,6 +1484,7 @@ syn keyword cmakeVariable contained
|
|||||||
\ MSVC_IDE
|
\ MSVC_IDE
|
||||||
\ MSVC_TOOLSET_VERSION
|
\ MSVC_TOOLSET_VERSION
|
||||||
\ MSVC_VERSION
|
\ MSVC_VERSION
|
||||||
|
\ MSYS
|
||||||
\ PROJECT_BINARY_DIR
|
\ PROJECT_BINARY_DIR
|
||||||
\ PROJECT_DESCRIPTION
|
\ PROJECT_DESCRIPTION
|
||||||
\ PROJECT_HOMEPAGE_URL
|
\ PROJECT_HOMEPAGE_URL
|
||||||
@@ -1592,6 +1565,7 @@ syn keyword cmakeKWExternalProject contained
|
|||||||
\ LOG_DOWNLOAD
|
\ LOG_DOWNLOAD
|
||||||
\ LOG_INSTALL
|
\ LOG_INSTALL
|
||||||
\ LOG_MERGED_STDOUTERR
|
\ LOG_MERGED_STDOUTERR
|
||||||
|
\ LOG_OUTPUT_ON_FAILURE
|
||||||
\ LOG_PATCH
|
\ LOG_PATCH
|
||||||
\ LOG_TEST
|
\ LOG_TEST
|
||||||
\ LOG_UPDATE
|
\ LOG_UPDATE
|
||||||
@@ -1645,6 +1619,7 @@ syn keyword cmakeKWadd_compile_options contained
|
|||||||
\ COMPILE_OPTIONS
|
\ COMPILE_OPTIONS
|
||||||
\ SHELL
|
\ SHELL
|
||||||
\ UNIX_COMMAND
|
\ UNIX_COMMAND
|
||||||
|
\ WX
|
||||||
|
|
||||||
syn keyword cmakeKWadd_custom_command contained
|
syn keyword cmakeKWadd_custom_command contained
|
||||||
\ APPEND
|
\ APPEND
|
||||||
@@ -1767,6 +1742,7 @@ syn keyword cmakeKWadd_test contained
|
|||||||
\ CONFIGURATIONS
|
\ CONFIGURATIONS
|
||||||
\ FAIL_REGULAR_EXPRESSION
|
\ FAIL_REGULAR_EXPRESSION
|
||||||
\ NAME
|
\ NAME
|
||||||
|
\ OFF
|
||||||
\ PASS_REGULAR_EXPRESSION
|
\ PASS_REGULAR_EXPRESSION
|
||||||
\ TARGET_FILE
|
\ TARGET_FILE
|
||||||
\ WILL_FAIL
|
\ WILL_FAIL
|
||||||
@@ -1818,6 +1794,7 @@ syn keyword cmakeKWcmake_parse_arguments contained
|
|||||||
\ MY_INSTALL_CONFIGURATIONS
|
\ MY_INSTALL_CONFIGURATIONS
|
||||||
\ MY_INSTALL_DESTINATION
|
\ MY_INSTALL_DESTINATION
|
||||||
\ MY_INSTALL_FAST
|
\ MY_INSTALL_FAST
|
||||||
|
\ MY_INSTALL_KEYWORDS_MISSING_VALUES
|
||||||
\ MY_INSTALL_OPTIONAL
|
\ MY_INSTALL_OPTIONAL
|
||||||
\ MY_INSTALL_RENAME
|
\ MY_INSTALL_RENAME
|
||||||
\ MY_INSTALL_TARGETS
|
\ MY_INSTALL_TARGETS
|
||||||
@@ -1828,6 +1805,7 @@ syn keyword cmakeKWcmake_parse_arguments contained
|
|||||||
\ TARGETS
|
\ TARGETS
|
||||||
\ TRUE
|
\ TRUE
|
||||||
\ UNDEFINED
|
\ UNDEFINED
|
||||||
|
\ _KEYWORDS_MISSING_VALUES
|
||||||
\ _UNPARSED_ARGUMENTS
|
\ _UNPARSED_ARGUMENTS
|
||||||
|
|
||||||
syn keyword cmakeKWcmake_policy contained
|
syn keyword cmakeKWcmake_policy contained
|
||||||
@@ -1926,6 +1904,7 @@ syn keyword cmakeKWctest_start contained
|
|||||||
|
|
||||||
syn keyword cmakeKWctest_submit contained
|
syn keyword cmakeKWctest_submit contained
|
||||||
\ API
|
\ API
|
||||||
|
\ BUILD_ID
|
||||||
\ CAPTURE_CMAKE_ERROR
|
\ CAPTURE_CMAKE_ERROR
|
||||||
\ CDASH_UPLOAD
|
\ CDASH_UPLOAD
|
||||||
\ CDASH_UPLOAD_TYPE
|
\ CDASH_UPLOAD_TYPE
|
||||||
@@ -1938,6 +1917,7 @@ syn keyword cmakeKWctest_submit contained
|
|||||||
\ RETRY_COUNT
|
\ RETRY_COUNT
|
||||||
\ RETRY_DELAY
|
\ RETRY_DELAY
|
||||||
\ RETURN_VALUE
|
\ RETURN_VALUE
|
||||||
|
\ SUBMIT_URL
|
||||||
|
|
||||||
syn keyword cmakeKWctest_test contained
|
syn keyword cmakeKWctest_test contained
|
||||||
\ APPEND
|
\ APPEND
|
||||||
@@ -1993,6 +1973,9 @@ syn keyword cmakeKWenable_language contained
|
|||||||
\ CUDA
|
\ CUDA
|
||||||
\ OPTIONAL
|
\ OPTIONAL
|
||||||
|
|
||||||
|
syn keyword cmakeKWenable_testing contained
|
||||||
|
\ BUILD_TESTING
|
||||||
|
|
||||||
syn keyword cmakeKWexec_program contained
|
syn keyword cmakeKWexec_program contained
|
||||||
\ ARGS
|
\ ARGS
|
||||||
\ OUTPUT_VARIABLE
|
\ OUTPUT_VARIABLE
|
||||||
@@ -2055,6 +2038,8 @@ syn keyword cmakeKWfile contained
|
|||||||
\ CONFIGURE_DEPENDS
|
\ CONFIGURE_DEPENDS
|
||||||
\ CONTENT
|
\ CONTENT
|
||||||
\ COPY
|
\ COPY
|
||||||
|
\ COPY_ON_ERROR
|
||||||
|
\ CREATE_LINK
|
||||||
\ DESTINATION
|
\ DESTINATION
|
||||||
\ DIRECTORY_PERMISSIONS
|
\ DIRECTORY_PERMISSIONS
|
||||||
\ DOWNLOAD
|
\ DOWNLOAD
|
||||||
@@ -2108,12 +2093,14 @@ syn keyword cmakeKWfile contained
|
|||||||
\ REMOVE_RECURSE
|
\ REMOVE_RECURSE
|
||||||
\ RENAME
|
\ RENAME
|
||||||
\ REQUIRED
|
\ REQUIRED
|
||||||
|
\ RESULT
|
||||||
\ RESULT_VARIABLE
|
\ RESULT_VARIABLE
|
||||||
\ SHOW_PROGRESS
|
\ SHOW_PROGRESS
|
||||||
\ SIZE
|
\ SIZE
|
||||||
\ SSL
|
\ SSL
|
||||||
\ STATUS
|
\ STATUS
|
||||||
\ STRINGS
|
\ STRINGS
|
||||||
|
\ SYMBOLIC
|
||||||
\ TIMESTAMP
|
\ TIMESTAMP
|
||||||
\ TLS_CAINFO
|
\ TLS_CAINFO
|
||||||
\ TLS_VERIFY
|
\ TLS_VERIFY
|
||||||
@@ -2295,8 +2282,10 @@ syn keyword cmakeKWget_filename_component contained
|
|||||||
\ BASE_DIR
|
\ BASE_DIR
|
||||||
\ DIRECTORY
|
\ DIRECTORY
|
||||||
\ EXT
|
\ EXT
|
||||||
|
\ LAST_EXT
|
||||||
\ NAME
|
\ NAME
|
||||||
\ NAME_WE
|
\ NAME_WE
|
||||||
|
\ NAME_WLE
|
||||||
\ PATH
|
\ PATH
|
||||||
\ PROGRAM
|
\ PROGRAM
|
||||||
\ PROGRAM_ARGS
|
\ PROGRAM_ARGS
|
||||||
@@ -2432,6 +2421,7 @@ syn keyword cmakeKWinstall contained
|
|||||||
\ EXPORT
|
\ EXPORT
|
||||||
\ EXPORT_ANDROID_MK
|
\ EXPORT_ANDROID_MK
|
||||||
\ EXPORT_LINK_INTERFACE_LIBRARIES
|
\ EXPORT_LINK_INTERFACE_LIBRARIES
|
||||||
|
\ EXPORT_NAME
|
||||||
\ FILES
|
\ FILES
|
||||||
\ FILES_MATCHING
|
\ FILES_MATCHING
|
||||||
\ FILE_PERMISSIONS
|
\ FILE_PERMISSIONS
|
||||||
@@ -2466,6 +2456,7 @@ syn keyword cmakeKWinstall contained
|
|||||||
\ PRE_INSTALL_SCRIPT
|
\ PRE_INSTALL_SCRIPT
|
||||||
\ PRIVATE_HEADER
|
\ PRIVATE_HEADER
|
||||||
\ PROGRAMS
|
\ PROGRAMS
|
||||||
|
\ PROPERTIES
|
||||||
\ PUBLIC_HEADER
|
\ PUBLIC_HEADER
|
||||||
\ REGEX
|
\ REGEX
|
||||||
\ RENAME
|
\ RENAME
|
||||||
@@ -2479,6 +2470,7 @@ syn keyword cmakeKWinstall contained
|
|||||||
\ SETUID
|
\ SETUID
|
||||||
\ SHAREDSTATE
|
\ SHAREDSTATE
|
||||||
\ SOVERSION
|
\ SOVERSION
|
||||||
|
\ STATIC
|
||||||
\ SYSCONF
|
\ SYSCONF
|
||||||
\ TARGETS
|
\ TARGETS
|
||||||
\ TRUE
|
\ TRUE
|
||||||
@@ -2533,6 +2525,8 @@ syn keyword cmakeKWlist contained
|
|||||||
\ ORDER
|
\ ORDER
|
||||||
\ OUTPUT_VARIABLE
|
\ OUTPUT_VARIABLE
|
||||||
\ PARENT_SCOPE
|
\ PARENT_SCOPE
|
||||||
|
\ POP_BACK
|
||||||
|
\ POP_FRONT
|
||||||
\ PREPEND
|
\ PREPEND
|
||||||
\ REGEX
|
\ REGEX
|
||||||
\ REMOVE_AT
|
\ REMOVE_AT
|
||||||
@@ -2613,6 +2607,12 @@ syn keyword cmakeKWproject contained
|
|||||||
\ _VERSION_PATCH
|
\ _VERSION_PATCH
|
||||||
\ _VERSION_TWEAK
|
\ _VERSION_TWEAK
|
||||||
|
|
||||||
|
syn keyword cmakeKWqt_wrap_cpp contained
|
||||||
|
\ AUTOMOC
|
||||||
|
|
||||||
|
syn keyword cmakeKWqt_wrap_ui contained
|
||||||
|
\ AUTOUIC
|
||||||
|
|
||||||
syn keyword cmakeKWremove contained
|
syn keyword cmakeKWremove contained
|
||||||
\ VALUE
|
\ VALUE
|
||||||
\ VAR
|
\ VAR
|
||||||
@@ -2635,6 +2635,7 @@ syn keyword cmakeKWset contained
|
|||||||
\ STRINGS
|
\ STRINGS
|
||||||
|
|
||||||
syn keyword cmakeKWset_directory_properties contained
|
syn keyword cmakeKWset_directory_properties contained
|
||||||
|
\ DIRECTORY
|
||||||
\ PROPERTIES
|
\ PROPERTIES
|
||||||
|
|
||||||
syn keyword cmakeKWset_property contained
|
syn keyword cmakeKWset_property contained
|
||||||
@@ -2652,6 +2653,7 @@ syn keyword cmakeKWset_property contained
|
|||||||
|
|
||||||
syn keyword cmakeKWset_source_files_properties contained
|
syn keyword cmakeKWset_source_files_properties contained
|
||||||
\ PROPERTIES
|
\ PROPERTIES
|
||||||
|
\ SOURCE
|
||||||
|
|
||||||
syn keyword cmakeKWset_target_properties contained
|
syn keyword cmakeKWset_target_properties contained
|
||||||
\ PROPERTIES
|
\ PROPERTIES
|
||||||
@@ -2659,6 +2661,7 @@ syn keyword cmakeKWset_target_properties contained
|
|||||||
|
|
||||||
syn keyword cmakeKWset_tests_properties contained
|
syn keyword cmakeKWset_tests_properties contained
|
||||||
\ PROPERTIES
|
\ PROPERTIES
|
||||||
|
\ TEST
|
||||||
|
|
||||||
syn keyword cmakeKWsource_group contained
|
syn keyword cmakeKWsource_group contained
|
||||||
\ FILES
|
\ FILES
|
||||||
@@ -2845,17 +2848,20 @@ syn keyword cmakeKWtry_compile contained
|
|||||||
\ DEFINED
|
\ DEFINED
|
||||||
\ DLINK_LIBRARIES
|
\ DLINK_LIBRARIES
|
||||||
\ DVAR
|
\ DVAR
|
||||||
|
\ EXECUTABLE
|
||||||
\ FALSE
|
\ FALSE
|
||||||
|
\ GHS
|
||||||
\ INCLUDE_DIRECTORIES
|
\ INCLUDE_DIRECTORIES
|
||||||
\ LANG
|
\ LANG
|
||||||
\ LINK_DIRECTORIES
|
\ LINK_DIRECTORIES
|
||||||
\ LINK_LIBRARIES
|
\ LINK_LIBRARIES
|
||||||
\ LINK_OPTIONS
|
\ LINK_OPTIONS
|
||||||
|
\ MULTI
|
||||||
\ NOT
|
\ NOT
|
||||||
\ OUTPUT_VARIABLE
|
\ OUTPUT_VARIABLE
|
||||||
\ PRIVATE
|
\ PRIVATE
|
||||||
\ RESULT_VAR
|
|
||||||
\ SOURCES
|
\ SOURCES
|
||||||
|
\ STATIC_LIBRARY
|
||||||
\ STATIC_LIBRARY_OPTIONS
|
\ STATIC_LIBRARY_OPTIONS
|
||||||
\ TRUE
|
\ TRUE
|
||||||
\ TYPE
|
\ TYPE
|
||||||
@@ -2869,7 +2875,6 @@ syn keyword cmakeKWtry_run contained
|
|||||||
\ CMAKE_FLAGS
|
\ CMAKE_FLAGS
|
||||||
\ COMPILE_DEFINITIONS
|
\ COMPILE_DEFINITIONS
|
||||||
\ COMPILE_OUTPUT_VARIABLE
|
\ COMPILE_OUTPUT_VARIABLE
|
||||||
\ COMPILE_RESULT_VAR
|
|
||||||
\ DLINK_LIBRARIES
|
\ DLINK_LIBRARIES
|
||||||
\ DVAR
|
\ DVAR
|
||||||
\ FAILED_TO_RUN
|
\ FAILED_TO_RUN
|
||||||
@@ -2879,7 +2884,6 @@ syn keyword cmakeKWtry_run contained
|
|||||||
\ LINK_LIBRARIES
|
\ LINK_LIBRARIES
|
||||||
\ LINK_OPTIONS
|
\ LINK_OPTIONS
|
||||||
\ RUN_OUTPUT_VARIABLE
|
\ RUN_OUTPUT_VARIABLE
|
||||||
\ RUN_RESULT_VAR
|
|
||||||
\ TRUE
|
\ TRUE
|
||||||
\ TYPE
|
\ TYPE
|
||||||
\ VALUE
|
\ VALUE
|
||||||
@@ -2924,7 +2928,8 @@ syn keyword cmakeGeneratorExpressions contained
|
|||||||
\ COMPILING_CXX
|
\ COMPILING_CXX
|
||||||
\ CONFIG
|
\ CONFIG
|
||||||
\ CONFIGURATION
|
\ CONFIGURATION
|
||||||
\ CUDA
|
\ CUDA_COMPILER_ID
|
||||||
|
\ CUDA_COMPILER_VERSION
|
||||||
\ CUSTOM_KEYS
|
\ CUSTOM_KEYS
|
||||||
\ CXX_COMPILER_ID
|
\ CXX_COMPILER_ID
|
||||||
\ CXX_COMPILER_VERSION
|
\ CXX_COMPILER_VERSION
|
||||||
@@ -2953,7 +2958,6 @@ syn keyword cmakeGeneratorExpressions contained
|
|||||||
\ LOWER_CASE
|
\ LOWER_CASE
|
||||||
\ MAKE_C_IDENTIFIER
|
\ MAKE_C_IDENTIFIER
|
||||||
\ MAP_IMPORTED_CONFIG_
|
\ MAP_IMPORTED_CONFIG_
|
||||||
\ MSYS
|
|
||||||
\ NO
|
\ NO
|
||||||
\ NOT
|
\ NOT
|
||||||
\ OBJECT_LIBRARY
|
\ OBJECT_LIBRARY
|
||||||
@@ -2964,6 +2968,7 @@ syn keyword cmakeGeneratorExpressions contained
|
|||||||
\ PDB_OUTPUT_DIRECTORY
|
\ PDB_OUTPUT_DIRECTORY
|
||||||
\ PDB_OUTPUT_DIRECTORY_
|
\ PDB_OUTPUT_DIRECTORY_
|
||||||
\ PLATFORM_ID
|
\ PLATFORM_ID
|
||||||
|
\ POSIX
|
||||||
\ PRIVATE
|
\ PRIVATE
|
||||||
\ PUBLIC
|
\ PUBLIC
|
||||||
\ SDK
|
\ SDK
|
||||||
@@ -3189,6 +3194,7 @@ hi def link cmakeKWctest_update ModeMsg
|
|||||||
hi def link cmakeKWctest_upload ModeMsg
|
hi def link cmakeKWctest_upload ModeMsg
|
||||||
hi def link cmakeKWdefine_property ModeMsg
|
hi def link cmakeKWdefine_property ModeMsg
|
||||||
hi def link cmakeKWenable_language ModeMsg
|
hi def link cmakeKWenable_language ModeMsg
|
||||||
|
hi def link cmakeKWenable_testing ModeMsg
|
||||||
hi def link cmakeKWexec_program ModeMsg
|
hi def link cmakeKWexec_program ModeMsg
|
||||||
hi def link cmakeKWexecute_process ModeMsg
|
hi def link cmakeKWexecute_process ModeMsg
|
||||||
hi def link cmakeKWexport ModeMsg
|
hi def link cmakeKWexport ModeMsg
|
||||||
@@ -3228,6 +3234,8 @@ hi def link cmakeKWmath ModeMsg
|
|||||||
hi def link cmakeKWmessage ModeMsg
|
hi def link cmakeKWmessage ModeMsg
|
||||||
hi def link cmakeKWoption ModeMsg
|
hi def link cmakeKWoption ModeMsg
|
||||||
hi def link cmakeKWproject ModeMsg
|
hi def link cmakeKWproject ModeMsg
|
||||||
|
hi def link cmakeKWqt_wrap_cpp ModeMsg
|
||||||
|
hi def link cmakeKWqt_wrap_ui ModeMsg
|
||||||
hi def link cmakeKWremove ModeMsg
|
hi def link cmakeKWremove ModeMsg
|
||||||
hi def link cmakeKWseparate_arguments ModeMsg
|
hi def link cmakeKWseparate_arguments ModeMsg
|
||||||
hi def link cmakeKWset ModeMsg
|
hi def link cmakeKWset ModeMsg
|
||||||
|
|||||||
@@ -309,7 +309,7 @@ if !exists('g:crystal_no_comment_fold')
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
" Note: this is a hack to prevent 'keywords' being highlighted as such when called as methods with an explicit receiver
|
" Note: this is a hack to prevent 'keywords' being highlighted as such when called as methods with an explicit receiver
|
||||||
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(alias\|begin\|break\|case\|class\|def\|defined\|do\|else\)\>" transparent contains=NONE
|
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(alias\|begin\|break\|case\|class\|def\|defined\|do\|else\|select\)\>" transparent contains=NONE
|
||||||
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(elsif\|end\|ensure\|false\|for\|if\|ifdef\|in\|module\|next\|nil\)\>" transparent contains=NONE
|
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(elsif\|end\|ensure\|false\|for\|if\|ifdef\|in\|module\|next\|nil\)\>" transparent contains=NONE
|
||||||
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(rescue\|return\|self\|super\|previous_def\|then\|true\)\>" transparent contains=NONE
|
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(rescue\|return\|self\|super\|previous_def\|then\|true\)\>" transparent contains=NONE
|
||||||
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(undef\|unless\|until\|when\|while\|yield\|with\|__FILE__\|__LINE__\)\>" transparent contains=NONE
|
syn match crystalKeywordAsMethod "\%(\%(\.\@<!\.\)\|::\)\_s*\%(undef\|unless\|until\|when\|while\|yield\|with\|__FILE__\|__LINE__\)\>" transparent contains=NONE
|
||||||
|
|||||||
@@ -31,10 +31,10 @@ syn keyword lispFunc ignore-stdout ignore-stderr ignore-outputs
|
|||||||
syn keyword lispFunc with-stdout-to with-stderr-to with-outputs-to
|
syn keyword lispFunc with-stdout-to with-stderr-to with-outputs-to
|
||||||
syn keyword lispFunc write-file system bash
|
syn keyword lispFunc write-file system bash
|
||||||
|
|
||||||
syn cluster lispBaseListCluster add=jbuildVar
|
syn cluster lispBaseListCluster add=duneVar
|
||||||
syn match jbuildVar '\${[@<^]}' containedin=lispSymbol
|
syn match duneVar '\${[@<^]}' containedin=lispSymbol
|
||||||
syn match jbuildVar '\${\k\+\(:\k\+\)\?}' containedin=lispSymbol
|
syn match duneVar '\${\k\+\(:\k\+\)\?}' containedin=lispSymbol
|
||||||
|
|
||||||
hi def link jbuildVar Identifier
|
hi def link duneVar Identifier
|
||||||
|
|
||||||
let b:current_syntax = "jbuild"
|
let b:current_syntax = "dune"
|
||||||
@@ -24,7 +24,10 @@ if !exists("b:eelixir_subtype")
|
|||||||
let b:eelixir_subtype = matchstr(&filetype,'^eex\.\zs\w\+')
|
let b:eelixir_subtype = matchstr(&filetype,'^eex\.\zs\w\+')
|
||||||
endif
|
endif
|
||||||
if b:eelixir_subtype == ''
|
if b:eelixir_subtype == ''
|
||||||
let b:eelixir_subtype = matchstr(substitute(expand("%:t"),'\c\%(\.eex\|\.eelixir\)\+$','',''),'\.\zs\w\+$')
|
let b:eelixir_subtype = matchstr(&filetype,'^leex\.\zs\w\+')
|
||||||
|
endif
|
||||||
|
if b:eelixir_subtype == ''
|
||||||
|
let b:eelixir_subtype = matchstr(substitute(expand("%:t"),'\c\%(\.eex\|\.leex\|\.eelixir\)\+$','',''),'\.\zs\w\+$')
|
||||||
endif
|
endif
|
||||||
if b:eelixir_subtype == 'ex'
|
if b:eelixir_subtype == 'ex'
|
||||||
let b:eelixir_subtype = 'elixir'
|
let b:eelixir_subtype = 'elixir'
|
||||||
|
|||||||
@@ -109,6 +109,12 @@ syn region elixirSigil matchgroup=elixirSigilDelimiter start="\~\l\/"
|
|||||||
syn region elixirSigil matchgroup=elixirSigilDelimiter start=+\~\a\z("""\)+ end=+^\s*\z1+ skip=+\\"+ fold
|
syn region elixirSigil matchgroup=elixirSigilDelimiter start=+\~\a\z("""\)+ end=+^\s*\z1+ skip=+\\"+ fold
|
||||||
syn region elixirSigil matchgroup=elixirSigilDelimiter start=+\~\a\z('''\)+ end=+^\s*\z1+ skip=+\\'+ fold
|
syn region elixirSigil matchgroup=elixirSigilDelimiter start=+\~\a\z('''\)+ end=+^\s*\z1+ skip=+\\'+ fold
|
||||||
|
|
||||||
|
|
||||||
|
" LiveView Sigils surrounded with ~L"""
|
||||||
|
syntax include @HTML syntax/html.vim
|
||||||
|
syntax region elixirLiveViewSigil matchgroup=elixirSigilDelimiter keepend start=+\~L\z("""\)+ end=+^\s*\z1+ skip=+\\"+ contains=@HTML fold
|
||||||
|
|
||||||
|
|
||||||
" Documentation
|
" Documentation
|
||||||
if exists('g:elixir_use_markdown_for_docs') && g:elixir_use_markdown_for_docs
|
if exists('g:elixir_use_markdown_for_docs') && g:elixir_use_markdown_for_docs
|
||||||
syn include @markdown syntax/markdown.vim
|
syn include @markdown syntax/markdown.vim
|
||||||
@@ -122,14 +128,14 @@ else
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]\z(/\|\"\|'\||\)" end="\z1" skip="\\\\\|\\\z1" contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]\z(/\|\"\|'\||\)" end="\z1" skip="\\\\\|\\\z1" contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]{" end="}" skip="\\\\\|\\}" contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]{" end="}" skip="\\\\\|\\}" contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]<" end=">" skip="\\\\\|\\>" contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]<" end=">" skip="\\\\\|\\>" contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]\[" end="\]" skip="\\\\\|\\\]" contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss]\[" end="\]" skip="\\\\\|\\\]" contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss](" end=")" skip="\\\\\|\\)" contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start="\%(@\w*doc\s\+\)\@<=\~[Ss](" end=")" skip="\\\\\|\\)" contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocStringDelimiter start=+\%(@\w*doc\s\+\)\@<=\z("\)+ end=+\z1+ skip=+\\\\\|\\\z1+ contains=@elixirDocStringContained keepend
|
syn region elixirDocString matchgroup=elixirDocStringDelimiter start=+\%(@\w*doc\s\+\)\@<=\z("\)+ end=+\z1+ skip=+\\\\\|\\\z1+ contains=@elixirDocStringContained keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocStringDelimiter start=+\%(@\w*doc\s\+\)\@<=\z("""\)+ end=+\z1+ contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocStringDelimiter start=+\%(@\w*doc\s\+\)\@<=\z("""\)+ end=+^\s*\z1+ contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start=+\%(@\w*doc\s\+\)\@<=\~[Ss]\z('''\)+ end=+\z1+ skip=+\\'+ contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start=+\%(@\w*doc\s\+\)\@<=\~[Ss]\z('''\)+ end=+^\s*\z1+ contains=@elixirDocStringContained fold keepend
|
||||||
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start=+\%(@\w*doc\s\+\)\@<=\~[Ss]\z("""\)+ end=+\z1+ skip=+\\"+ contains=@elixirDocStringContained fold keepend
|
syn region elixirDocString matchgroup=elixirDocSigilDelimiter start=+\%(@\w*doc\s\+\)\@<=\~[Ss]\z("""\)+ end=+^\s*\z1+ contains=@elixirDocStringContained fold keepend
|
||||||
|
|
||||||
" Defines
|
" Defines
|
||||||
syn match elixirDefine '\<def\>\(:\)\@!' nextgroup=elixirFunctionDeclaration skipwhite skipnl
|
syn match elixirDefine '\<def\>\(:\)\@!' nextgroup=elixirFunctionDeclaration skipwhite skipnl
|
||||||
|
|||||||
@@ -46,6 +46,7 @@ syn match elmFloat "\(\<\d\+\.\d\+\>\)"
|
|||||||
|
|
||||||
" Identifiers
|
" Identifiers
|
||||||
syn match elmTopLevelDecl "^\s*[a-zA-Z][a-zA-z0-9_]*\('\)*\s\+:\(\r\n\|\r\|\n\|\s\)\+" contains=elmOperator
|
syn match elmTopLevelDecl "^\s*[a-zA-Z][a-zA-z0-9_]*\('\)*\s\+:\(\r\n\|\r\|\n\|\s\)\+" contains=elmOperator
|
||||||
|
syn match elmFuncName /^\l\w*/
|
||||||
|
|
||||||
" Folding
|
" Folding
|
||||||
syn region elmTopLevelTypedef start="type" end="\n\(\n\n\)\@=" contains=ALL fold
|
syn region elmTopLevelTypedef start="type" end="\n\(\n\n\)\@=" contains=ALL fold
|
||||||
@@ -54,6 +55,7 @@ syn region elmCaseBlock matchgroup=elmCaseBlockDefinition start="^\z\(\s\+\)\<ca
|
|||||||
syn region elmCaseItemBlock start="^\z\(\s\+\).\+->$" end="^\z1\@!\W\@=" end="\(\n\n\z1\@!\)\@=" end="\(\n\z1\S\)\@=" contains=ALL fold
|
syn region elmCaseItemBlock start="^\z\(\s\+\).\+->$" end="^\z1\@!\W\@=" end="\(\n\n\z1\@!\)\@=" end="\(\n\z1\S\)\@=" contains=ALL fold
|
||||||
syn region elmLetBlock matchgroup=elmLetBlockDefinition start="\<let\>" end="\<in\>" contains=ALL fold
|
syn region elmLetBlock matchgroup=elmLetBlockDefinition start="\<let\>" end="\<in\>" contains=ALL fold
|
||||||
|
|
||||||
|
hi def link elmFuncName Function
|
||||||
hi def link elmCaseBlockDefinition Conditional
|
hi def link elmCaseBlockDefinition Conditional
|
||||||
hi def link elmCaseBlockItemDefinition Conditional
|
hi def link elmCaseBlockItemDefinition Conditional
|
||||||
hi def link elmLetBlockDefinition TypeDef
|
hi def link elmLetBlockDefinition TypeDef
|
||||||
|
|||||||
@@ -42,25 +42,48 @@ highlight default link gomodReplaceOperator Operator
|
|||||||
|
|
||||||
|
|
||||||
" highlight versions:
|
" highlight versions:
|
||||||
|
" * vX.Y.Z-pre
|
||||||
" * vX.Y.Z
|
" * vX.Y.Z
|
||||||
" * vX.0.0-yyyyymmddhhmmss-abcdefabcdef
|
" * vX.0.0-yyyyymmddhhmmss-abcdefabcdef
|
||||||
" * vX.Y.Z-pre.0.yyyymmddhhmmss-abcdefabcdef
|
" * vX.Y.Z-pre.0.yyyymmddhhmmss-abcdefabcdef
|
||||||
" * vX.Y.(Z+1)-0.yyyymmddhhss-abcdefabcdef
|
" * vX.Y.(Z+1)-0.yyyymmddhhss-abcdefabcdef
|
||||||
" * +incompatible suffix when X > 1
|
" see https://godoc.org/golang.org/x/tools/internal/semver for more
|
||||||
|
" information about how semantic versions are parsed and
|
||||||
|
" https://golang.org/cmd/go/ for how pseudo-versions and +incompatible
|
||||||
|
" are applied.
|
||||||
|
|
||||||
|
|
||||||
" match vX.Y.Z and their prereleases
|
" match vX.Y.Z and their prereleases
|
||||||
syntax match gomodVersion "v\d\+\.\d\+\.\d\+\%(-\%(\w\+\.\)\+0\.\d\{14}-\x\+\)\?"
|
syntax match gomodVersion "v\d\+\.\d\+\.\d\+\%(-\%([0-9A-Za-z-]\+\)\%(\.[0-9A-Za-z-]\+\)*\)\?\%(+\%([0-9A-Za-z-]\+\)\(\.[0-9A-Za-z-]\+\)*\)\?"
|
||||||
" match target when most recent version before the target is X.Y.Z
|
" ^--- version ---^^------------ pre-release ---------------------^^--------------- metadata ---------------------^
|
||||||
syntax match gomodVersion "v\d\+\.\d\+\.[1-9]\{1}\d*\%(-0\.\%(\d\{14}-\x\+\)\)\?"
|
" ^--------------------------------------- semantic version -------------------------------------------------------^
|
||||||
" match target without a major version before the commit (e.g. vX.0.0-yyyymmddhhmmss-abcdefabcdef)
|
|
||||||
syntax match gomodVersion "v\d\+\.0\.0-\d\{14\}-\x\+"
|
|
||||||
|
|
||||||
" match vX.Y.Z and their prereleases for X>1
|
" match pseudo versions
|
||||||
syntax match gomodVersion "v[2-9]\{1}\d\?\.\d\+\.\d\+\%(-\%(\w\+\.\)\+0\.\d\{14\}-\x\+\)\?\%(+incompatible\>\)\?"
|
" without a major version before the commit (e.g. vX.0.0-yyyymmddhhmmss-abcdefabcdef)
|
||||||
" match target when most recent version before the target is X.Y.Z for X>1
|
syntax match gomodVersion "v\d\+\.0\.0-\d\{14\}-\x\+"
|
||||||
syntax match gomodVersion "v[2-9]\{1}\d\?\.\d\+\.[1-9]\{1}\d*\%(-0\.\%(\d\{14\}-\x\+\)\)\?\%(+incompatible\>\)\?"
|
" when most recent version before target is a pre-release
|
||||||
" match target without a major version before the commit (e.g. vX.0.0-yyyymmddhhmmss-abcdefabcdef) for X>1
|
syntax match gomodVersion "v\d\+\.\d\+\.\d\+-\%([0-9A-Za-z-]\+\)\%(\.[0-9A-Za-z-]\+\)*\%(+\%([0-9A-Za-z-]\+\)\(\.[0-9A-Za-z-]\+\)*\)\?\.0\.\d\{14}-\x\+"
|
||||||
syntax match gomodVersion "v[2-9]\{1}\d\?\.0\.0-\d\{14\}-\x\+\%(+incompatible\>\)\?"
|
" ^--- version ---^^--- ------ pre-release -----------------^^--------------- metadata ---------------------^
|
||||||
|
" ^------------------------------------- semantic version --------------------------------------------------^
|
||||||
|
" most recent version before the target is X.Y.Z
|
||||||
|
syntax match gomodVersion "v\d\+\.\d\+\.\d\+\%(+\%([0-9A-Za-z-]\+\)\(\.[0-9A-Za-z-]\+\)*\)\?-0\.\d\{14}-\x\+"
|
||||||
|
" ^--- version ---^^--------------- metadata ---------------------^
|
||||||
|
|
||||||
|
" match incompatible vX.Y.Z and their prereleases
|
||||||
|
syntax match gomodVersion "v[2-9]\{1}\d*\.\d\+\.\d\+\%(-\%([0-9A-Za-z-]\+\)\%(\.[0-9A-Za-z-]\+\)*\)\?\%(+\%([0-9A-Za-z-]\+\)\(\.[0-9A-Za-z-]\+\)*\)\?+incompatible"
|
||||||
|
" ^------- version -------^^------------- pre-release ---------------------^^--------------- metadata ---------------------^
|
||||||
|
" ^------------------------------------------- semantic version -----------------------------------------------------------^
|
||||||
|
|
||||||
|
" match incompatible pseudo versions
|
||||||
|
" incompatible without a major version before the commit (e.g. vX.0.0-yyyymmddhhmmss-abcdefabcdef)
|
||||||
|
syntax match gomodVersion "v[2-9]\{1}\d*\.0\.0-\d\{14\}-\x\++incompatible"
|
||||||
|
" when most recent version before target is a pre-release
|
||||||
|
syntax match gomodVersion "v[2-9]\{1}\d*\.\d\+\.\d\+-\%([0-9A-Za-z-]\+\)\%(\.[0-9A-Za-z-]\+\)*\%(+\%([0-9A-Za-z-]\+\)\(\.[0-9A-Za-z-]\+\)*\)\?\.0\.\d\{14}-\x\++incompatible"
|
||||||
|
" ^------- version -------^^---------- pre-release -----------------^^--------------- metadata ---------------------^
|
||||||
|
" ^---------------------------------------- semantic version ------------------------------------------------------^
|
||||||
|
" most recent version before the target is X.Y.Z
|
||||||
|
syntax match gomodVersion "v[2-9]\{1}\d*\.\d\+\.\d\+\%(+\%([0-9A-Za-z-]\+\)\%(\.[0-9A-Za-z-]\+\)*\)\?-0\.\d\{14}-\x\++incompatible"
|
||||||
|
" ^------- version -------^^---------------- metadata ---------------------^
|
||||||
highlight default link gomodVersion Identifier
|
highlight default link gomodVersion Identifier
|
||||||
|
|
||||||
let b:current_syntax = "gomod"
|
let b:current_syntax = "gomod"
|
||||||
|
|||||||
@@ -1,68 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'graphql') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Vim syntax file
|
|
||||||
" Language: GraphQL
|
|
||||||
" Maintainer: Jon Parise <jon@indelible.org>
|
|
||||||
|
|
||||||
if exists('b:current_syntax')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
syn match graphqlComment "#.*$" contains=@Spell
|
|
||||||
|
|
||||||
syn match graphqlOperator "=" display
|
|
||||||
syn match graphqlOperator "!" display
|
|
||||||
syn match graphqlOperator "|" display
|
|
||||||
syn match graphqlOperator "\M..." display
|
|
||||||
|
|
||||||
syn keyword graphqlBoolean true false
|
|
||||||
syn keyword graphqlNull null
|
|
||||||
syn match graphqlNumber "-\=\<\%(0\|[1-9]\d*\)\%(\.\d\+\)\=\%([eE][-+]\=\d\+\)\=\>" display
|
|
||||||
syn region graphqlString start=+"+ skip=+\\\\\|\\"+ end=+"\|$+
|
|
||||||
syn region graphqlString start=+"""+ end=+"""+
|
|
||||||
|
|
||||||
syn keyword graphqlKeyword on nextgroup=graphqlType skipwhite
|
|
||||||
|
|
||||||
syn keyword graphqlStructure enum scalar type union nextgroup=graphqlType skipwhite
|
|
||||||
syn keyword graphqlStructure input interface subscription nextgroup=graphqlType skipwhite
|
|
||||||
syn keyword graphqlStructure implements nextgroup=graphqlType skipwhite
|
|
||||||
syn keyword graphqlStructure query mutation fragment nextgroup=graphqlName skipwhite
|
|
||||||
syn keyword graphqlStructure directive nextgroup=graphqlDirective skipwhite
|
|
||||||
syn keyword graphqlStructure extend nextgroup=graphqlStructure skipwhite
|
|
||||||
syn keyword graphqlStructure schema nextgroup=graphqlFold skipwhite
|
|
||||||
|
|
||||||
syn match graphqlDirective "\<@\h\w*\>" display
|
|
||||||
syn match graphqlVariable "\<\$\h\w*\>" display
|
|
||||||
syn match graphqlName "\<\h\w*\>" display
|
|
||||||
syn match graphqlType "\<_*\u\w*\>" display
|
|
||||||
syn match graphqlConstant "\<[A-Z_]\+\>" display
|
|
||||||
|
|
||||||
syn keyword graphqlMetaFields __schema __type __typename
|
|
||||||
|
|
||||||
syn region graphqlFold matchgroup=graphqlBraces start="{" end="}" transparent fold contains=ALLBUT,graphqlStructure
|
|
||||||
syn region graphqlList matchgroup=graphqlBraces start="\[" end="]" transparent contains=ALLBUT,graphqlDirective,graphqlStructure
|
|
||||||
|
|
||||||
hi def link graphqlComment Comment
|
|
||||||
hi def link graphqlOperator Operator
|
|
||||||
|
|
||||||
hi def link graphqlBraces Delimiter
|
|
||||||
|
|
||||||
hi def link graphqlBoolean Boolean
|
|
||||||
hi def link graphqlNull Keyword
|
|
||||||
hi def link graphqlNumber Number
|
|
||||||
hi def link graphqlString String
|
|
||||||
|
|
||||||
hi def link graphqlConstant Constant
|
|
||||||
hi def link graphqlDirective PreProc
|
|
||||||
hi def link graphqlName Identifier
|
|
||||||
hi def link graphqlMetaFields Special
|
|
||||||
hi def link graphqlKeyword Keyword
|
|
||||||
hi def link graphqlStructure Structure
|
|
||||||
hi def link graphqlType Type
|
|
||||||
hi def link graphqlVariable Identifier
|
|
||||||
|
|
||||||
syn sync minlines=500
|
|
||||||
|
|
||||||
let b:current_syntax = 'graphql'
|
|
||||||
@@ -5,8 +5,8 @@ endif
|
|||||||
" Vim syntax file
|
" Vim syntax file
|
||||||
" Language: i3 config file
|
" Language: i3 config file
|
||||||
" Maintainer: Mohamed Boughaba <mohamed dot bgb at gmail dot com>
|
" Maintainer: Mohamed Boughaba <mohamed dot bgb at gmail dot com>
|
||||||
" Version: 0.3
|
" Version: 0.4
|
||||||
" Last Change: 2017-10-27 23:59
|
" Last Change: 2019-03-23 21:54
|
||||||
|
|
||||||
" References:
|
" References:
|
||||||
" http://i3wm.org/docs/userguide.html#configuring
|
" http://i3wm.org/docs/userguide.html#configuring
|
||||||
@@ -24,231 +24,231 @@ en
|
|||||||
scriptencoding utf-8
|
scriptencoding utf-8
|
||||||
|
|
||||||
" Error
|
" Error
|
||||||
syn match Error /.*/
|
syn match i3ConfigError /.*/
|
||||||
|
|
||||||
" Todo
|
" Todo
|
||||||
syn keyword Todo TODO FIXME XXX contained
|
syn keyword i3ConfigTodo TODO FIXME XXX contained
|
||||||
|
|
||||||
" Comment
|
" Comment
|
||||||
" Comments are started with a # and can only be used at the beginning of a line
|
" Comments are started with a # and can only be used at the beginning of a line
|
||||||
syn match Comment /^\s*#.*$/ contains=Todo
|
syn match i3ConfigComment /^\s*#.*$/ contains=i3ConfigTodo
|
||||||
|
|
||||||
" Font
|
" Font
|
||||||
" A FreeType font description is composed by:
|
" A FreeType font description is composed by:
|
||||||
" a font family, a style, a weight, a variant, a stretch and a size.
|
" a font family, a style, a weight, a variant, a stretch and a size.
|
||||||
syn match FontSeparator /,/ contained
|
syn match i3ConfigFontSeparator /,/ contained
|
||||||
syn match FontSeparator /:/ contained
|
syn match i3ConfigFontSeparator /:/ contained
|
||||||
syn keyword FontKeyword font contained
|
syn keyword i3ConfigFontKeyword font contained
|
||||||
syn match FontNamespace /\w\+:/ contained contains=FontSeparator
|
syn match i3ConfigFontNamespace /\w\+:/ contained contains=i3ConfigFontSeparator
|
||||||
syn match FontContent /-\?\w\+\(-\+\|\s\+\|,\)/ contained contains=FontNamespace,FontSeparator,FontKeyword
|
syn match i3ConfigFontContent /-\?\w\+\(-\+\|\s\+\|,\)/ contained contains=i3ConfigFontNamespace,i3ConfigFontSeparator,i3ConfigFontKeyword
|
||||||
syn match FontSize /\s\=\d\+\(px\)\?\s\?$/ contained
|
syn match i3ConfigFontSize /\s\=\d\+\(px\)\?\s\?$/ contained
|
||||||
syn match Font /^\s*font\s\+.*$/ contains=FontContent,FontSeparator,FontSize,FontNamespace
|
syn match i3ConfigFont /^\s*font\s\+.*$/ contains=i3ConfigFontContent,i3ConfigFontSeparator,i3ConfigFontSize,i3ConfigFontNamespace
|
||||||
"syn match Font /^\s*font\s\+.*\(\\\_.*\)\?$/ contains=FontContent,FontSeparator,FontSize,FontNamespace
|
"syn match i3ConfigFont /^\s*font\s\+.*\(\\\_.*\)\?$/ contains=i3ConfigFontContent,i3ConfigFontSeparator,i3ConfigFontSize,i3ConfigFontNamespace
|
||||||
"syn match Font /^\s*font\s\+.*\(\\\_.*\)\?[^\\]\+$/ contains=FontContent,FontSeparator,FontSize,FontNamespace
|
"syn match i3ConfigFont /^\s*font\s\+.*\(\\\_.*\)\?[^\\]\+$/ contains=i3ConfigFontContent,i3ConfigFontSeparator,i3ConfigFontSize,i3ConfigFontNamespace
|
||||||
"syn match Font /^\s*font\s\+\(\(.*\\\_.*\)\|\(.*[^\\]\+$\)\)/ contains=FontContent,FontSeparator,FontSize,FontNamespace
|
"syn match i3ConfigFont /^\s*font\s\+\(\(.*\\\_.*\)\|\(.*[^\\]\+$\)\)/ contains=i3ConfigFontContent,i3ConfigFontSeparator,i3ConfigFontSize,i3ConfigFontNamespace
|
||||||
|
|
||||||
" variables
|
" variables
|
||||||
syn match String /\(['"]\)\(.\{-}\)\1/ contained
|
syn match i3ConfigString /\(['"]\)\(.\{-}\)\1/ contained
|
||||||
syn match Color /#\w\{6}/ contained
|
syn match i3ConfigColor /#\w\{6}/ contained
|
||||||
syn match VariableModifier /+/ contained
|
syn match i3ConfigVariableModifier /+/ contained
|
||||||
syn match VariableAndModifier /+\w\+/ contained contains=VariableModifier
|
syn match i3ConfigVariableAndModifier /+\w\+/ contained contains=i3ConfigVariableModifier
|
||||||
syn match Variable /\$\w\+\(\(-\w\+\)\+\)\?\(\s\|+\)\?/ contains=VariableModifier,VariableAndModifier
|
syn match i3ConfigVariable /\$\w\+\(\(-\w\+\)\+\)\?\(\s\|+\)\?/ contains=i3ConfigVariableModifier,i3ConfigVariableAndModifier
|
||||||
syn keyword InitializeKeyword set contained
|
syn keyword i3ConfigInitializeKeyword set contained
|
||||||
syn match Initialize /^\s*set\s\+.*$/ contains=Variable,InitializeKeyword,Color,String
|
syn match i3ConfigInitialize /^\s*set\s\+.*$/ contains=i3ConfigVariable,i3ConfigInitializeKeyword,i3ConfigColor,i3ConfigString
|
||||||
|
|
||||||
" Gaps
|
" Gaps
|
||||||
syn keyword GapStyleKeyword inner outer horizontal vertical top right bottom left current all set plus minus toggle contained
|
syn keyword i3ConfigGapStyleKeyword inner outer horizontal vertical top right bottom left current all set plus minus toggle contained
|
||||||
syn match GapStyle /^\s*\(gaps\)\s\+\(inner\|outer\|horizontal\|vertical\|left\|top\|right\|bottom\)\(\s\+\(current\|all\)\)\?\(\s\+\(set\|plus\|minus\|toggle\)\)\?\(\s\+\(\d\+\|\$.*\)\)$/ contains=GapStyleKeyword,number,Variable
|
syn match i3ConfigGapStyle /^\s*\(gaps\)\s\+\(inner\|outer\|horizontal\|vertical\|left\|top\|right\|bottom\)\(\s\+\(current\|all\)\)\?\(\s\+\(set\|plus\|minus\|toggle\)\)\?\(\s\+\(-\?\d\+\|\$.*\)\)$/ contains=i3ConfigGapStyleKeyword,number,i3ConfigVariable
|
||||||
syn keyword SmartGapKeyword on inverse_outer contained
|
syn keyword i3ConfigSmartGapKeyword on inverse_outer contained
|
||||||
syn match SmartGap /^\s*smart_gaps\s\+\(on\|inverse_outer\)\s\?$/ contains=SmartGapKeyword
|
syn match i3ConfigSmartGap /^\s*smart_gaps\s\+\(on\|inverse_outer\)\s\?$/ contains=i3ConfigSmartGapKeyword
|
||||||
syn keyword SmartBorderKeyword on no_gaps contained
|
syn keyword i3ConfigSmartBorderKeyword on no_gaps contained
|
||||||
syn match SmartBorder /^\s*smart_borders\s\+\(on\|no_gaps\)\s\?$/ contains=SmartBorderKeyword
|
syn match i3ConfigSmartBorder /^\s*smart_borders\s\+\(on\|no_gaps\)\s\?$/ contains=i3ConfigSmartBorderKeyword
|
||||||
|
|
||||||
" Keyboard bindings
|
" Keyboard bindings
|
||||||
syn keyword Action toggle fullscreen restart key import kill shrink grow contained
|
syn keyword i3ConfigAction toggle fullscreen restart key import kill shrink grow contained
|
||||||
syn keyword Action focus move split layout resize restore reload mute unmute exit contained
|
syn keyword i3ConfigAction focus move split layout resize restore reload mute unmute exit contained
|
||||||
syn match Modifier /\w\++\w\+\(\(+\w\+\)\+\)\?/ contained contains=VariableModifier
|
syn match i3ConfigModifier /\w\++\w\+\(\(+\w\+\)\+\)\?/ contained contains=i3ConfigVariableModifier
|
||||||
syn match Number /\s\d\+/ contained
|
syn match i3ConfigNumber /\s\d\+/ contained
|
||||||
syn keyword BindKeyword bindsym bindcode exec gaps contained
|
syn keyword i3ConfigBindKeyword bindsym bindcode exec gaps contained
|
||||||
syn match BindArgument /--\w\+\(\(-\w\+\)\+\)\?\s/ contained
|
syn match i3ConfigBindArgument /--\w\+\(\(-\w\+\)\+\)\?\s/ contained
|
||||||
syn match Bind /^\s*\(bindsym\|bindcode\)\s\+.*$/ contains=Variable,BindKeyword,VariableAndModifier,BindArgument,Number,Modifier,Action,String,GapStyleKeyword
|
syn match i3ConfigBind /^\s*\(bindsym\|bindcode\)\s\+.*$/ contains=i3ConfigVariable,i3ConfigBindKeyword,i3ConfigVariableAndModifier,i3ConfigBindArgument,i3ConfigNumber,i3ConfigModifier,i3ConfigAction,i3ConfigString,i3ConfigGapStyleKeyword
|
||||||
|
|
||||||
" Floating
|
" Floating
|
||||||
syn keyword SizeSpecial x contained
|
syn keyword i3ConfigSizeSpecial x contained
|
||||||
syn match NegativeSize /-/ contained
|
syn match i3ConfigNegativeSize /-/ contained
|
||||||
syn match Size /-\?\d\+\s\?x\s\?-\?\d\+/ contained contains=SizeSpecial,Number,NegativeSize
|
syn match i3ConfigSize /-\?\d\+\s\?x\s\?-\?\d\+/ contained contains=i3ConfigSizeSpecial,i3ConfigNumber,i3ConfigNegativeSize
|
||||||
syn match Floating /^\s*floating_modifier\s\+\$\w\+\d\?/ contains=Variable
|
syn match i3ConfigFloating /^\s*floating_modifier\s\+\$\w\+\d\?/ contains=i3ConfigVariable
|
||||||
syn match Floating /^\s*floating_\(maximum\|minimum\)_size\s\+-\?\d\+\s\?x\s\?-\?\d\+/ contains=Size
|
syn match i3ConfigFloating /^\s*floating_\(maximum\|minimum\)_size\s\+-\?\d\+\s\?x\s\?-\?\d\+/ contains=Size
|
||||||
|
|
||||||
" Orientation
|
" Orientation
|
||||||
syn keyword OrientationKeyword vertical horizontal auto contained
|
syn keyword i3ConfigOrientationKeyword vertical horizontal auto contained
|
||||||
syn match Orientation /^\s*default_orientation\s\+\(vertical\|horizontal\|auto\)\s\?$/ contains=OrientationKeyword
|
syn match i3ConfigOrientation /^\s*default_orientation\s\+\(vertical\|horizontal\|auto\)\s\?$/ contains=i3ConfigOrientationKeyword
|
||||||
|
|
||||||
" Layout
|
" Layout
|
||||||
syn keyword LayoutKeyword default stacking tabbed contained
|
syn keyword i3ConfigLayoutKeyword default stacking tabbed contained
|
||||||
syn match Layout /^\s*workspace_layout\s\+\(default\|stacking\|tabbed\)\s\?$/ contains=LayoutKeyword
|
syn match i3ConfigLayout /^\s*workspace_layout\s\+\(default\|stacking\|tabbed\)\s\?$/ contains=i3ConfigLayoutKeyword
|
||||||
|
|
||||||
" Border style
|
" Border style
|
||||||
syn keyword BorderStyleKeyword none normal pixel contained
|
syn keyword i3ConfigBorderStyleKeyword none normal pixel contained
|
||||||
syn match BorderStyle /^\s*\(new_window\|new_float\|default_border\|default_floating_border\)\s\+\(none\|\(normal\|pixel\)\(\s\+\d\+\)\?\)\s\?$/ contains=BorderStyleKeyword,number
|
syn match i3ConfigBorderStyle /^\s*\(new_window\|new_float\|default_border\|default_floating_border\)\s\+\(none\|\(normal\|pixel\)\(\s\+\d\+\)\?\)\s\?$/ contains=i3ConfigBorderStyleKeyword,number
|
||||||
|
|
||||||
" Hide borders and edges
|
" Hide borders and edges
|
||||||
syn keyword EdgeKeyword none vertical horizontal both smart smart_no_gaps contained
|
syn keyword i3ConfigEdgeKeyword none vertical horizontal both smart smart_no_gaps contained
|
||||||
syn match Edge /^\s*hide_edge_borders\s\+\(none\|vertical\|horizontal\|both\|smart\|smart_no_gaps\)\s\?$/ contains=EdgeKeyword
|
syn match i3ConfigEdge /^\s*hide_edge_borders\s\+\(none\|vertical\|horizontal\|both\|smart\|smart_no_gaps\)\s\?$/ contains=i3ConfigEdgeKeyword
|
||||||
|
|
||||||
" Arbitrary commands for specific windows (for_window)
|
" Arbitrary commands for specific windows (for_window)
|
||||||
syn keyword CommandKeyword for_window contained
|
syn keyword i3ConfigCommandKeyword for_window contained
|
||||||
syn region WindowStringSpecial start=+"+ skip=+\\"+ end=+"+ contained contains=String
|
syn region i3ConfigWindowStringSpecial start=+"+ skip=+\\"+ end=+"+ contained contains=i3ConfigString
|
||||||
syn region WindowCommandSpecial start="\[" end="\]" contained contains=WindowStringSpacial,String
|
syn region i3ConfigWindowCommandSpecial start="\[" end="\]" contained contains=WindowStringSpacial,i3ConfigString
|
||||||
syn match ArbitraryCommand /^\s*for_window\s\+.*$/ contains=WindowCommandSpecial,CommandKeyword,BorderStyleKeyword,LayoutKeyword,OrientationKeyword,Size,Number
|
syn match i3ConfigArbitraryCommand /^\s*for_window\s\+.*$/ contains=i3ConfigWindowCommandSpecial,i3ConfigCommandKeyword,i3ConfigBorderStyleKeyword,i3ConfigLayoutKeyword,i3ConfigOrientationKeyword,Size,i3ConfigNumber
|
||||||
|
|
||||||
" Disable focus open opening
|
" Disable focus open opening
|
||||||
syn keyword NoFocusKeyword no_focus contained
|
syn keyword i3ConfigNoFocusKeyword no_focus contained
|
||||||
syn match DisableFocus /^\s*no_focus\s\+.*$/ contains=WindowCommandSpecial,NoFocusKeyword
|
syn match i3ConfigDisableFocus /^\s*no_focus\s\+.*$/ contains=i3ConfigWindowCommandSpecial,i3ConfigNoFocusKeyword
|
||||||
|
|
||||||
" Move client to specific workspace automatically
|
" Move client to specific workspace automatically
|
||||||
syn keyword AssignKeyword assign contained
|
syn keyword i3ConfigAssignKeyword assign contained
|
||||||
syn match AssignSpecial /→/ contained
|
syn match i3ConfigAssignSpecial /→/ contained
|
||||||
syn match Assign /^\s*assign\s\+.*$/ contains=AssignKeyword,WindowCommandSpecial,AssignSpecial
|
syn match i3ConfigAssign /^\s*assign\s\+.*$/ contains=i3ConfigAssignKeyword,i3ConfigWindowCommandSpecial,i3ConfigAssignSpecial
|
||||||
|
|
||||||
" X resources
|
" X resources
|
||||||
syn keyword ResourceKeyword set_from_resource contained
|
syn keyword i3ConfigResourceKeyword set_from_resource contained
|
||||||
syn match Resource /^\s*set_from_resource\s\+.*$/ contains=ResourceKeyword,WindowCommandSpecial,Color,Variable
|
syn match i3ConfigResource /^\s*set_from_resource\s\+.*$/ contains=i3ConfigResourceKeyword,i3ConfigWindowCommandSpecial,i3ConfigColor,i3ConfigVariable
|
||||||
|
|
||||||
" Auto start applications
|
" Auto start applications
|
||||||
syn keyword ExecKeyword exec exec_always contained
|
syn keyword i3ConfigExecKeyword exec exec_always contained
|
||||||
syn match NoStartupId /--no-startup-id/ contained " We are not using BindArgument as only no-startup-id is supported here
|
syn match i3ConfigNoStartupId /--no-startup-id/ contained " We are not using i3ConfigBindArgument as only no-startup-id is supported here
|
||||||
syn match Exec /^\s*exec\(_always\)\?\s\+.*$/ contains=ExecKeyword,NoStartupId,String
|
syn match i3ConfigExec /^\s*exec\(_always\)\?\s\+.*$/ contains=i3ConfigExecKeyword,i3ConfigNoStartupId,i3ConfigString
|
||||||
|
|
||||||
" Automatically putting workspaces on specific screens
|
" Automatically putting workspaces on specific screens
|
||||||
syn keyword WorkspaceKeyword workspace contained
|
syn keyword i3ConfigWorkspaceKeyword workspace contained
|
||||||
syn keyword Output output contained
|
syn keyword i3ConfigOutput output contained
|
||||||
syn match Workspace /^\s*workspace\s\+.*$/ contains=WorkspaceKeyword,Number,String,Output
|
syn match i3ConfigWorkspace /^\s*workspace\s\+.*$/ contains=i3ConfigWorkspaceKeyword,i3ConfigNumber,i3ConfigString,i3ConfigOutput
|
||||||
|
|
||||||
" Changing colors
|
" Changing colors
|
||||||
syn keyword ClientColorKeyword client focused focused_inactive unfocused urgent placeholder background contained
|
syn keyword i3ConfigClientColorKeyword client focused focused_inactive unfocused urgent placeholder background contained
|
||||||
syn match ClientColor /^\s*client.\w\+\s\+.*$/ contains=ClientColorKeyword,Color,Variable
|
syn match i3ConfigClientColor /^\s*client.\w\+\s\+.*$/ contains=i3ConfigClientColorKeyword,i3ConfigColor,i3ConfigVariable
|
||||||
|
|
||||||
" Interprocess communication
|
" Interprocess communication
|
||||||
syn match InterprocessKeyword /ipc-socket/ contained
|
syn match i3ConfigInterprocessKeyword /ipc-socket/ contained
|
||||||
syn match Interprocess /^\s*ipc-socket\s\+.*$/ contains=InterprocessKeyword
|
syn match i3ConfigInterprocess /^\s*ipc-socket\s\+.*$/ contains=i3ConfigInterprocessKeyword
|
||||||
|
|
||||||
" Mouse warping
|
" Mouse warping
|
||||||
syn keyword MouseWarpingKeyword mouse_warping contained
|
syn keyword i3ConfigMouseWarpingKeyword mouse_warping contained
|
||||||
syn keyword MouseWarpingType output none contained
|
syn keyword i3ConfigMouseWarpingType output none contained
|
||||||
syn match MouseWarping /^\s*mouse_warping\s\+\(output\|none\)\s\?$/ contains=MouseWarpingKeyword,MouseWarpingType
|
syn match i3ConfigMouseWarping /^\s*mouse_warping\s\+\(output\|none\)\s\?$/ contains=i3ConfigMouseWarpingKeyword,i3ConfigMouseWarpingType
|
||||||
|
|
||||||
" Focus follows mouse
|
" Focus follows mouse
|
||||||
syn keyword FocusFollowsMouseKeyword focus_follows_mouse contained
|
syn keyword i3ConfigFocusFollowsMouseKeyword focus_follows_mouse contained
|
||||||
syn keyword FocusFollowsMouseType yes no contained
|
syn keyword i3ConfigFocusFollowsMouseType yes no contained
|
||||||
syn match FocusFollowsMouse /^\s*focus_follows_mouse\s\+\(yes\|no\)\s\?$/ contains=FocusFollowsMouseKeyword,FocusFollowsMouseType
|
syn match i3ConfigFocusFollowsMouse /^\s*focus_follows_mouse\s\+\(yes\|no\)\s\?$/ contains=i3ConfigFocusFollowsMouseKeyword,i3ConfigFocusFollowsMouseType
|
||||||
|
|
||||||
" Popups during fullscreen mode
|
" Popups during fullscreen mode
|
||||||
syn keyword PopupOnFullscreenKeyword popup_during_fullscreen contained
|
syn keyword i3ConfigPopupOnFullscreenKeyword popup_during_fullscreen contained
|
||||||
syn keyword PopuponFullscreenType smart ignore leave_fullscreen contained
|
syn keyword i3ConfigPopuponFullscreenType smart ignore leave_fullscreen contained
|
||||||
syn match PopupOnFullscreen /^\s*popup_during_fullscreen\s\+\w\+\s\?$/ contains=PopupOnFullscreenKeyword,PopupOnFullscreenType
|
syn match i3ConfigPopupOnFullscreen /^\s*popup_during_fullscreen\s\+\w\+\s\?$/ contains=i3ConfigPopupOnFullscreenKeyword,i3ConfigPopupOnFullscreenType
|
||||||
|
|
||||||
" Focus wrapping
|
" Focus wrapping
|
||||||
syn keyword FocusWrappingKeyword force_focus_wrapping focus_wrapping contained
|
syn keyword i3ConfigFocusWrappingKeyword force_focus_wrapping focus_wrapping contained
|
||||||
syn keyword FocusWrappingType yes no contained
|
syn keyword i3ConfigFocusWrappingType yes no contained
|
||||||
syn match FocusWrapping /^\s*\(force_\)\?focus_wrapping\s\+\(yes\|no\)\s\?$/ contains=FocusWrappingType,FocusWrappingKeyword
|
syn match i3ConfigFocusWrapping /^\s*\(force_\)\?focus_wrapping\s\+\(yes\|no\)\s\?$/ contains=i3ConfigFocusWrappingType,i3ConfigFocusWrappingKeyword
|
||||||
|
|
||||||
" Forcing Xinerama
|
" Forcing Xinerama
|
||||||
syn keyword ForceXineramaKeyword force_xinerama contained
|
syn keyword i3ConfigForceXineramaKeyword force_xinerama contained
|
||||||
syn match ForceXinerama /^\s*force_xinerama\s\+\(yes\|no\)\s\?$/ contains=FocusWrappingType,ForceXineramaKeyword
|
syn match i3ConfigForceXinerama /^\s*force_xinerama\s\+\(yes\|no\)\s\?$/ contains=i3ConfigFocusWrappingType,i3ConfigForceXineramaKeyword
|
||||||
|
|
||||||
" Automatic back-and-forth when switching to the current workspace
|
" Automatic back-and-forth when switching to the current workspace
|
||||||
syn keyword AutomaticSwitchKeyword workspace_auto_back_and_forth contained
|
syn keyword i3ConfigAutomaticSwitchKeyword workspace_auto_back_and_forth contained
|
||||||
syn match AutomaticSwitch /^\s*workspace_auto_back_and_forth\s\+\(yes\|no\)\s\?$/ contains=FocusWrappingType,AutomaticSwitchKeyword
|
syn match i3ConfigAutomaticSwitch /^\s*workspace_auto_back_and_forth\s\+\(yes\|no\)\s\?$/ contains=i3ConfigFocusWrappingType,i3ConfigAutomaticSwitchKeyword
|
||||||
|
|
||||||
" Delay urgency hint
|
" Delay urgency hint
|
||||||
syn keyword TimeUnit ms contained
|
syn keyword i3ConfigTimeUnit ms contained
|
||||||
syn keyword DelayUrgencyKeyword force_display_urgency_hint contained
|
syn keyword i3ConfigDelayUrgencyKeyword force_display_urgency_hint contained
|
||||||
syn match DelayUrgency /^\s*force_display_urgency_hint\s\+\d\+\s\+ms\s\?$/ contains=FocusWrappingType,DelayUrgencyKeyword,Number,TimeUnit
|
syn match i3ConfigDelayUrgency /^\s*force_display_urgency_hint\s\+\d\+\s\+ms\s\?$/ contains=i3ConfigFocusWrappingType,i3ConfigDelayUrgencyKeyword,i3ConfigNumber,i3ConfigTimeUnit
|
||||||
|
|
||||||
" Focus on window activation
|
" Focus on window activation
|
||||||
syn keyword FocusOnActivationKeyword focus_on_window_activation contained
|
syn keyword i3ConfigFocusOnActivationKeyword focus_on_window_activation contained
|
||||||
syn keyword FocusOnActivationType smart urgent focus none contained
|
syn keyword i3ConfigFocusOnActivationType smart urgent focus none contained
|
||||||
syn match FocusOnActivation /^\s*focus_on_window_activation\s\+\(smart\|urgent\|focus\|none\)\s\?$/ contains=FocusOnActivationKeyword,FocusOnActivationType
|
syn match i3ConfigFocusOnActivation /^\s*focus_on_window_activation\s\+\(smart\|urgent\|focus\|none\)\s\?$/ contains=i3ConfigFocusOnActivationKeyword,i3ConfigFocusOnActivationType
|
||||||
|
|
||||||
" Automatic back-and-forth when switching to the current workspace
|
" Automatic back-and-forth when switching to the current workspace
|
||||||
syn keyword DrawingMarksKeyword show_marks contained
|
syn keyword i3ConfigDrawingMarksKeyword show_marks contained
|
||||||
syn match DrawingMarks /^\s*show_marks\s\+\(yes\|no\)\s\?$/ contains=FocusWrappingType,DrawingMarksKeyword
|
syn match i3ConfigDrawingMarks /^\s*show_marks\s\+\(yes\|no\)\s\?$/ contains=i3ConfigFocusWrappingType,i3ConfigDrawingMarksKeyword
|
||||||
|
|
||||||
" Group mode/bar
|
" Group mode/bar
|
||||||
syn keyword BlockKeyword mode bar colors i3bar_command status_command position exec mode hidden_state modifier id position output background statusline tray_output tray_padding separator separator_symbol workspace_buttons strip_workspace_numbers binding_mode_indicator focused_workspace active_workspace inactive_workspace urgent_workspace binding_mode contained
|
syn keyword i3ConfigBlockKeyword mode bar colors i3bar_command status_command position exec mode hidden_state modifier id position output background statusline tray_output tray_padding separator separator_symbol workspace_buttons strip_workspace_numbers binding_mode_indicator focused_workspace active_workspace inactive_workspace urgent_workspace binding_mode contained
|
||||||
syn region Block start=+.*s\?{$+ end=+^}$+ contains=BlockKeyword,String,Bind,Comment,Font,FocusWrappingType,Color,Variable transparent keepend extend
|
syn region i3ConfigBlock start=+.*s\?{$+ end=+^}$+ contains=i3ConfigBlockKeyword,i3ConfigString,Bind,i3ConfigComment,Font,i3ConfigFocusWrappingType,i3ConfigColor,i3ConfigVariable transparent keepend extend
|
||||||
|
|
||||||
" Line continuation
|
" Line continuation
|
||||||
syn region LineCont start=/^.*\\$/ end=/^.*$/ contains=BlockKeyword,String,Bind,Comment,Font,FocusWrappingType,Color,Variable transparent keepend extend
|
syn region i3ConfigLineCont start=/^.*\\$/ end=/^.*$/ contains=i3ConfigBlockKeyword,i3ConfigString,Bind,i3ConfigComment,Font,i3ConfigFocusWrappingType,i3ConfigColor,i3ConfigVariable transparent keepend extend
|
||||||
|
|
||||||
" Define the highlighting.
|
" Define the highlighting.
|
||||||
hi! def link Error Error
|
hi! def link i3ConfigError Error
|
||||||
hi! def link Todo Todo
|
hi! def link i3ConfigTodo Todo
|
||||||
hi! def link Comment Comment
|
hi! def link i3ConfigComment Comment
|
||||||
hi! def link FontContent Type
|
hi! def link i3ConfigFontContent Type
|
||||||
hi! def link FocusOnActivationType Type
|
hi! def link i3ConfigFocusOnActivationType Type
|
||||||
hi! def link PopupOnFullscreenType Type
|
hi! def link i3ConfigPopupOnFullscreenType Type
|
||||||
hi! def link OrientationKeyword Type
|
hi! def link i3ConfigOrientationKeyword Type
|
||||||
hi! def link MouseWarpingType Type
|
hi! def link i3ConfigMouseWarpingType Type
|
||||||
hi! def link FocusFollowsMouseType Type
|
hi! def link i3ConfigFocusFollowsMouseType Type
|
||||||
hi! def link GapStyleKeyword Type
|
hi! def link i3ConfigGapStyleKeyword Type
|
||||||
hi! def link SmartGapKeyword Type
|
hi! def link i3ConfigSmartGapKeyword Type
|
||||||
hi! def link SmartBorderKeyword Type
|
hi! def link i3ConfigSmartBorderKeyword Type
|
||||||
hi! def link LayoutKeyword Type
|
hi! def link i3ConfigLayoutKeyword Type
|
||||||
hi! def link BorderStyleKeyword Type
|
hi! def link i3ConfigBorderStyleKeyword Type
|
||||||
hi! def link EdgeKeyword Type
|
hi! def link i3ConfigEdgeKeyword Type
|
||||||
hi! def link Action Type
|
hi! def link i3ConfigAction Type
|
||||||
hi! def link Command Type
|
hi! def link i3ConfigCommand Type
|
||||||
hi! def link Output Type
|
hi! def link i3ConfigOutput Type
|
||||||
hi! def link WindowCommandSpecial Type
|
hi! def link i3ConfigWindowCommandSpecial Type
|
||||||
hi! def link FocusWrappingType Type
|
hi! def link i3ConfigFocusWrappingType Type
|
||||||
hi! def link FontSize Constant
|
hi! def link i3ConfigFontSize Constant
|
||||||
hi! def link Color Constant
|
hi! def link i3ConfigColor Constant
|
||||||
hi! def link Number Constant
|
hi! def link i3ConfigNumber Constant
|
||||||
hi! def link VariableAndModifier Constant
|
hi! def link i3ConfigVariableAndModifier Constant
|
||||||
hi! def link TimeUnit Constant
|
hi! def link i3ConfigTimeUnit Constant
|
||||||
hi! def link Modifier Constant
|
hi! def link i3ConfigModifier Constant
|
||||||
hi! def link String Constant
|
hi! def link i3ConfigString Constant
|
||||||
hi! def link NegativeSize Constant
|
hi! def link i3ConfigNegativeSize Constant
|
||||||
hi! def link FontSeparator Special
|
hi! def link i3ConfigFontSeparator Special
|
||||||
hi! def link VariableModifier Special
|
hi! def link i3ConfigVariableModifier Special
|
||||||
hi! def link SizeSpecial Special
|
hi! def link i3ConfigSizeSpecial Special
|
||||||
hi! def link WindowSpecial Special
|
hi! def link i3ConfigWindowSpecial Special
|
||||||
hi! def link AssignSpecial Special
|
hi! def link i3ConfigAssignSpecial Special
|
||||||
hi! def link FontNamespace PreProc
|
hi! def link i3ConfigFontNamespace PreProc
|
||||||
hi! def link BindArgument PreProc
|
hi! def link i3ConfigBindArgument PreProc
|
||||||
hi! def link NoStartupId PreProc
|
hi! def link i3ConfigNoStartupId PreProc
|
||||||
hi! def link FontKeyword Identifier
|
hi! def link i3ConfigFontKeyword Identifier
|
||||||
hi! def link BindKeyword Identifier
|
hi! def link i3ConfigBindKeyword Identifier
|
||||||
hi! def link Orientation Identifier
|
hi! def link i3ConfigOrientation Identifier
|
||||||
hi! def link GapStyle Identifier
|
hi! def link i3ConfigGapStyle Identifier
|
||||||
hi! def link SmartGap Identifier
|
hi! def link i3ConfigSmartGap Identifier
|
||||||
hi! def link SmartBorder Identifier
|
hi! def link i3ConfigSmartBorder Identifier
|
||||||
hi! def link Layout Identifier
|
hi! def link i3ConfigLayout Identifier
|
||||||
hi! def link BorderStyle Identifier
|
hi! def link i3ConfigBorderStyle Identifier
|
||||||
hi! def link Edge Identifier
|
hi! def link i3ConfigEdge Identifier
|
||||||
hi! def link Floating Identifier
|
hi! def link i3ConfigFloating Identifier
|
||||||
hi! def link CommandKeyword Identifier
|
hi! def link i3ConfigCommandKeyword Identifier
|
||||||
hi! def link NoFocusKeyword Identifier
|
hi! def link i3ConfigNoFocusKeyword Identifier
|
||||||
hi! def link InitializeKeyword Identifier
|
hi! def link i3ConfigInitializeKeyword Identifier
|
||||||
hi! def link AssignKeyword Identifier
|
hi! def link i3ConfigAssignKeyword Identifier
|
||||||
hi! def link ResourceKeyword Identifier
|
hi! def link i3ConfigResourceKeyword Identifier
|
||||||
hi! def link ExecKeyword Identifier
|
hi! def link i3ConfigExecKeyword Identifier
|
||||||
hi! def link WorkspaceKeyword Identifier
|
hi! def link i3ConfigWorkspaceKeyword Identifier
|
||||||
hi! def link ClientColorKeyword Identifier
|
hi! def link i3ConfigClientColorKeyword Identifier
|
||||||
hi! def link InterprocessKeyword Identifier
|
hi! def link i3ConfigInterprocessKeyword Identifier
|
||||||
hi! def link MouseWarpingKeyword Identifier
|
hi! def link i3ConfigMouseWarpingKeyword Identifier
|
||||||
hi! def link FocusFollowsMouseKeyword Identifier
|
hi! def link i3ConfigFocusFollowsMouseKeyword Identifier
|
||||||
hi! def link PopupOnFullscreenKeyword Identifier
|
hi! def link i3ConfigPopupOnFullscreenKeyword Identifier
|
||||||
hi! def link FocusWrappingKeyword Identifier
|
hi! def link i3ConfigFocusWrappingKeyword Identifier
|
||||||
hi! def link ForceXineramaKeyword Identifier
|
hi! def link i3ConfigForceXineramaKeyword Identifier
|
||||||
hi! def link AutomaticSwitchKeyword Identifier
|
hi! def link i3ConfigAutomaticSwitchKeyword Identifier
|
||||||
hi! def link DelayUrgencyKeyword Identifier
|
hi! def link i3ConfigDelayUrgencyKeyword Identifier
|
||||||
hi! def link FocusOnActivationKeyword Identifier
|
hi! def link i3ConfigFocusOnActivationKeyword Identifier
|
||||||
hi! def link DrawingMarksKeyword Identifier
|
hi! def link i3ConfigDrawingMarksKeyword Identifier
|
||||||
hi! def link BlockKeyword Identifier
|
hi! def link i3ConfigBlockKeyword Identifier
|
||||||
hi! def link Variable Statement
|
hi! def link i3ConfigVariable Statement
|
||||||
hi! def link ArbitraryCommand Type
|
hi! def link i3ConfigArbitraryCommand Type
|
||||||
|
|
||||||
let b:current_syntax = "i3config"
|
let b:current_syntax = "i3config"
|
||||||
|
|||||||
@@ -153,14 +153,16 @@ syntax region jsFinallyBlock contained matchgroup=jsFinallyBraces s
|
|||||||
syntax region jsSwitchBlock contained matchgroup=jsSwitchBraces start=/{/ end=/}/ contains=@jsAll,jsBlock,jsSwitchCase extend fold
|
syntax region jsSwitchBlock contained matchgroup=jsSwitchBraces start=/{/ end=/}/ contains=@jsAll,jsBlock,jsSwitchCase extend fold
|
||||||
syntax region jsRepeatBlock contained matchgroup=jsRepeatBraces start=/{/ end=/}/ contains=@jsAll,jsBlock extend fold
|
syntax region jsRepeatBlock contained matchgroup=jsRepeatBraces start=/{/ end=/}/ contains=@jsAll,jsBlock extend fold
|
||||||
syntax region jsDestructuringBlock contained matchgroup=jsDestructuringBraces start=/{/ end=/}/ contains=jsDestructuringProperty,jsDestructuringAssignment,jsDestructuringNoise,jsDestructuringPropertyComputed,jsSpreadExpression,jsComment nextgroup=jsFlowDefinition extend fold
|
syntax region jsDestructuringBlock contained matchgroup=jsDestructuringBraces start=/{/ end=/}/ contains=jsDestructuringProperty,jsDestructuringAssignment,jsDestructuringNoise,jsDestructuringPropertyComputed,jsSpreadExpression,jsComment nextgroup=jsFlowDefinition extend fold
|
||||||
syntax region jsDestructuringArray contained matchgroup=jsDestructuringBraces start=/\[/ end=/\]/ contains=jsDestructuringPropertyValue,jsNoise,jsDestructuringProperty,jsSpreadExpression,jsDestructuringBlock,jsDestructuringArray,jsComment nextgroup=jsFlowDefinition extend fold
|
syntax region jsDestructuringArray contained matchgroup=jsDestructuringBraces start=/\[/ end=/\]/ contains=jsDestructuringPropertyValue,jsDestructuringNoise,jsDestructuringProperty,jsSpreadExpression,jsDestructuringBlock,jsDestructuringArray,jsComment nextgroup=jsFlowDefinition extend fold
|
||||||
syntax region jsObject contained matchgroup=jsObjectBraces start=/{/ end=/}/ contains=jsObjectKey,jsObjectKeyString,jsObjectKeyComputed,jsObjectShorthandProp,jsObjectSeparator,jsObjectFuncName,jsObjectMethodType,jsGenerator,jsComment,jsObjectStringKey,jsSpreadExpression,jsDecorator,jsAsyncKeyword extend fold
|
syntax region jsObject contained matchgroup=jsObjectBraces start=/{/ end=/}/ contains=jsObjectKey,jsObjectKeyString,jsObjectKeyComputed,jsObjectShorthandProp,jsObjectSeparator,jsObjectFuncName,jsObjectMethodType,jsGenerator,jsComment,jsObjectStringKey,jsSpreadExpression,jsDecorator,jsAsyncKeyword extend fold
|
||||||
syntax region jsBlock matchgroup=jsBraces start=/{/ end=/}/ contains=@jsAll,jsSpreadExpression extend fold
|
syntax region jsBlock matchgroup=jsBraces start=/{/ end=/}/ contains=@jsAll,jsSpreadExpression extend fold
|
||||||
syntax region jsModuleGroup contained matchgroup=jsModuleBraces start=/{/ end=/}/ contains=jsModuleKeyword,jsModuleComma,jsModuleAs,jsComment,jsFlowTypeKeyword skipwhite skipempty nextgroup=jsFrom fold
|
syntax region jsModuleGroup contained matchgroup=jsModuleBraces start=/{/ end=/}/ contains=jsModuleKeyword,jsModuleComma,jsModuleAs,jsComment,jsFlowTypeKeyword skipwhite skipempty nextgroup=jsFrom fold
|
||||||
syntax region jsSpreadExpression contained matchgroup=jsSpreadOperator start=/\.\.\./ end=/[,}\]]\@=/ contains=@jsExpression
|
syntax region jsSpreadExpression contained matchgroup=jsSpreadOperator start=/\.\.\./ end=/[,}\]]\@=/ contains=@jsExpression
|
||||||
syntax region jsRestExpression contained matchgroup=jsRestOperator start=/\.\.\./ end=/[,)]\@=/
|
syntax region jsRestExpression contained matchgroup=jsRestOperator start=/\.\.\./ end=/[,)]\@=/
|
||||||
syntax region jsTernaryIf matchgroup=jsTernaryIfOperator start=/?:\@!/ end=/\%(:\|}\@=\)/ contains=@jsExpression extend skipwhite skipempty nextgroup=@jsExpression
|
syntax region jsTernaryIf matchgroup=jsTernaryIfOperator start=/?:\@!/ end=/\%(:\|}\@=\)/ contains=@jsExpression extend skipwhite skipempty nextgroup=@jsExpression
|
||||||
syntax match jsOperator /?\.\ze\_D/
|
" These must occur here or they will be override by jsTernaryIf
|
||||||
|
syntax match jsOperator /?\.\ze\_D/
|
||||||
|
syntax match jsOperator /??/ skipwhite skipempty nextgroup=@jsExpression
|
||||||
|
|
||||||
syntax match jsGenerator contained /\*/ skipwhite skipempty nextgroup=jsFuncName,jsFuncArgs,jsFlowFunctionGroup
|
syntax match jsGenerator contained /\*/ skipwhite skipempty nextgroup=jsFuncName,jsFuncArgs,jsFlowFunctionGroup
|
||||||
syntax match jsFuncName contained /\<\K\k*/ skipwhite skipempty nextgroup=jsFuncArgs,jsFlowFunctionGroup
|
syntax match jsFuncName contained /\<\K\k*/ skipwhite skipempty nextgroup=jsFuncArgs,jsFlowFunctionGroup
|
||||||
|
|||||||
@@ -2,48 +2,64 @@ if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'json5') != -1
|
|||||||
finish
|
finish
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Syntax setup {{{1
|
" Modified from the original taken from https://github.com/gutenye/json5.vim
|
||||||
|
|
||||||
|
" Syntax setup
|
||||||
if exists('b:current_syntax') && b:current_syntax == 'json5'
|
if exists('b:current_syntax') && b:current_syntax == 'json5'
|
||||||
finish
|
finish
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Syntax: Strings {{{1
|
" Numbers
|
||||||
syn region json5String start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=json5Escape
|
syn match json5Number "[-+]\=\%(0\|[1-9]\d*\)\%(\.\d*\)\=\%([eE][-+]\=\d\+\)\="
|
||||||
syn region json5String start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=json5Escape
|
syn match json5Number "[-+]\=\%(\.\d\+\)\%([eE][-+]\=\d\+\)\="
|
||||||
|
syn match json5Number "[-+]\=0[xX]\x*"
|
||||||
|
syn match json5Number "[-+]\=Infinity\|NaN"
|
||||||
|
|
||||||
" Syntax: Escape sequences
|
" An integer part of 0 followed by other digits is not allowed
|
||||||
syn match json5Escape "\\["\\/bfnrt]" contained
|
syn match json5NumError "[-+]\=0\d\(\d\|\.\)*"
|
||||||
|
|
||||||
|
" A hexadecimal number cannot have a fractional part
|
||||||
|
syn match json5NumError "[-+]\=0x\x*\.\x*"
|
||||||
|
|
||||||
|
" Strings
|
||||||
|
syn region json5String start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=json5Escape,@Spell
|
||||||
|
syn region json5String start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=json5Escape,@Spell
|
||||||
|
|
||||||
|
" Escape sequences
|
||||||
|
syn match json5Escape "\\['\"\\bfnrtv]" contained
|
||||||
syn match json5Escape "\\u\x\{4}" contained
|
syn match json5Escape "\\u\x\{4}" contained
|
||||||
|
|
||||||
" Syntax: Numbers {{{1
|
" Boolean
|
||||||
syn match json5Number "-\=\<\%(0\|[1-9]\d*\)\%(\.\d\+\)\=\%([eE][-+]\=\d\+\)\=\>"
|
|
||||||
syn keyword json5Number Infinity -Infinity
|
|
||||||
|
|
||||||
" Syntax: An integer part of 0 followed by other digits is not allowed.
|
|
||||||
syn match json5NumError "-\=\<0\d\.\d*\>"
|
|
||||||
|
|
||||||
" Syntax: Boolean {{{1
|
|
||||||
syn keyword json5Boolean true false
|
syn keyword json5Boolean true false
|
||||||
|
|
||||||
" Syntax: Null {{{1
|
" Null
|
||||||
syn keyword json5Null null
|
syn keyword json5Null null
|
||||||
|
|
||||||
" Syntax: Braces {{{1
|
" Delimiters and Operators
|
||||||
|
syn match json5Delimiter ","
|
||||||
|
syn match json5Operator ":"
|
||||||
|
|
||||||
|
" Braces
|
||||||
syn match json5Braces "[{}\[\]]"
|
syn match json5Braces "[{}\[\]]"
|
||||||
syn match json5ObjAssign /@\?\%(\I\|\$\)\%(\i\|\$\)*\s*\ze::\@!/
|
|
||||||
|
|
||||||
" Syntax: Comment {{{1
|
" Keys
|
||||||
syn region json5LineComment start=+\/\/+ end=+$+ keepend
|
syn match json5Key /@\?\%(\I\|\$\)\%(\i\|\$\)*\s*\ze::\@!/ contains=@Spell
|
||||||
syn region json5LineComment start=+^\s*\/\/+ skip=+\n\s*\/\/+ end=+$+ keepend fold
|
syn match json5Key /"\([^"]\|\\"\)\{-}"\ze\s*:/ contains=json5Escape,@Spell
|
||||||
syn region json5Comment start="/\*" end="\*/" fold
|
|
||||||
|
|
||||||
" Define the default highlighting. {{{1
|
" Comment
|
||||||
|
syn region json5LineComment start=+\/\/+ end=+$+ keepend contains=@Spell
|
||||||
|
syn region json5LineComment start=+^\s*\/\/+ skip=+\n\s*\/\/+ end=+$+ keepend fold contains=@Spell
|
||||||
|
syn region json5Comment start="/\*" end="\*/" fold contains=@Spell
|
||||||
|
|
||||||
|
" Define the default highlighting
|
||||||
hi def link json5String String
|
hi def link json5String String
|
||||||
hi def link json5ObjAssign Identifier
|
hi def link json5Key Identifier
|
||||||
hi def link json5Escape Special
|
hi def link json5Escape Special
|
||||||
hi def link json5Number Number
|
hi def link json5Number Number
|
||||||
hi def link json5Braces Operator
|
hi def link json5Delimiter Delimiter
|
||||||
hi def link json5Null Function
|
hi def link json5Operator Operator
|
||||||
|
hi def link json5Braces Delimiter
|
||||||
|
hi def link json5Null Keyword
|
||||||
hi def link json5Boolean Boolean
|
hi def link json5Boolean Boolean
|
||||||
hi def link json5LineComment Comment
|
hi def link json5LineComment Comment
|
||||||
hi def link json5Comment Comment
|
hi def link json5Comment Comment
|
||||||
@@ -53,4 +69,3 @@ if !exists('b:current_syntax')
|
|||||||
let b:current_syntax = 'json5'
|
let b:current_syntax = 'json5'
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" vim: fdm=marker
|
|
||||||
|
|||||||
@@ -66,16 +66,16 @@ let s:nonidS_chars = "[:space:])\\U5D}" . s:nonid_chars
|
|||||||
" the following excludes '!' since it can be used as an identifier,
|
" the following excludes '!' since it can be used as an identifier,
|
||||||
" and '$' since it can be used in interpolations
|
" and '$' since it can be used in interpolations
|
||||||
" note that \U2D is '-'
|
" note that \U2D is '-'
|
||||||
let s:uniop_chars = "+\\U2D~¬√∛∜"
|
let s:uniop_chars = "+\\U2D~¬√∛∜⋆"
|
||||||
|
|
||||||
let s:binop_chars = "=+\\U2D*/\\%÷^&|⊻<>≤≥≡≠≢∈∉⋅×∪∩⊆⊈⊂⊄⊊←→∋∌⊕⊖⊞⊟∘∧⊗⊘↑↓∨⊠±"
|
let s:binop_chars = "=+\\U2D*/\\%÷^&|⊻<>≤≥≡≠≢∈∉⋅×∪∩⊆⊈⊂⊄⊊←→∋∌⊕⊖⊞⊟∘∧⊗⊘↑↓∨⊠±⟂⋆"
|
||||||
|
|
||||||
" the following is a list of all remainig valid operator chars,
|
" the following is a list of all remainig valid operator chars,
|
||||||
" but it's more efficient when expressed with ranges (see below)
|
" but it's more efficient when expressed with ranges (see below)
|
||||||
" let s:binop_chars_extra = "↔↚↛↠↣↦↮⇎⇏⇒⇔⇴⇶⇷⇸⇹⇺⇻⇼⇽⇾⇿⟵⟶⟷⟷⟹⟺⟻⟼⟽⟾⟿⤀⤁⤂⤃⤄⤅⤆⤇⤌⤍⤎⤏⤐⤑⤔⤕⤖⤗⤘⤝⤞⤟⤠⥄⥅⥆⥇⥈⥊⥋⥎⥐⥒⥓⥖⥗⥚⥛⥞⥟⥢⥤⥦⥧⥨⥩⥪⥫⥬⥭⥰⧴⬱⬰⬲⬳⬴⬵⬶⬷⬸⬹⬺⬻⬼⬽⬾⬿⭀⭁⭂⭃⭄⭇⭈⭉⭊⭋⭌←→" .
|
" let s:binop_chars_extra = "↔↚↛↠↣↦↮⇎⇏⇒⇔⇴⇶⇷⇸⇹⇺⇻⇼⇽⇾⇿⟵⟶⟷⟷⟹⟺⟻⟼⟽⟾⟿⤀⤁⤂⤃⤄⤅⤆⤇⤌⤍⤎⤏⤐⤑⤔⤕⤖⤗⤘⤝⤞⤟⤠⥄⥅⥆⥇⥈⥊⥋⥎⥐⥒⥓⥖⥗⥚⥛⥞⥟⥢⥤⥦⥧⥨⥩⥪⥫⥬⥭⥰⧴⬱⬰⬲⬳⬴⬵⬶⬷⬸⬹⬺⬻⬼⬽⬾⬿⭀⭁⭂⭃⭄⭇⭈⭉⭊⭋⭌←→" .
|
||||||
" \ "∝∊∍∥∦∷∺∻∽∾≁≃≄≅≆≇≈≉≊≋≌≍≎≐≑≒≓≔≕≖≗≘≙≚≛≜≝≞≟≣≦≧≨≩≪≫≬≭≮≯≰≱≲≳≴≵≶≷≸≹≺≻≼≽≾≿⊀⊁⊃⊅⊇⊉⊋⊏⊐⊑⊒⊜⊩⊬⊮⊰⊱⊲⊳⊴⊵⊶⊷⋍⋐⋑⋕⋖⋗⋘⋙⋚⋛⋜⋝⋞⋟⋠⋡⋢⋣⋤⋥⋦⋧⋨⋩⋪⋫⋬⋭⋲⋳⋴⋵⋶⋷⋸⋹⋺⋻⋼⋽⋾⋿⟈⟉⟒⦷⧀⧁⧡⧣⧤⧥⩦⩧⩪⩫⩬⩭⩮⩯⩰⩱⩲⩳⩴⩵⩶⩷⩸⩹⩺⩻⩼⩽⩾⩿⪀⪁⪂⪃⪄⪅⪆⪇⪈⪉⪊⪋⪌⪍⪎⪏⪐⪑⪒⪓⪔⪕⪖⪗⪘⪙⪚⪛⪜⪝⪞⪟⪠⪡⪢⪣⪤⪥⪦⪧⪨⪩⪪⪫⪬⪭⪮⪯⪰⪱⪲⪳⪴⪵⪶⪷⪸⪹⪺⪻⪼⪽⪾⪿⫀⫁⫂⫃⫄⫅⫆⫇⫈⫉⫊⫋⫌⫍⫎⫏⫐⫑⫒⫓⫔⫕⫖⫗⫘⫙⫷⫸⫹⫺⊢⊣" .
|
" \ "∝∊∍∥∦∷∺∻∽∾≁≃≄≅≆≇≈≉≊≋≌≍≎≐≑≒≓≔≕≖≗≘≙≚≛≜≝≞≟≣≦≧≨≩≪≫≬≭≮≯≰≱≲≳≴≵≶≷≸≹≺≻≼≽≾≿⊀⊁⊃⊅⊇⊉⊋⊏⊐⊑⊒⊜⊩⊬⊮⊰⊱⊲⊳⊴⊵⊶⊷⋍⋐⋑⋕⋖⋗⋘⋙⋚⋛⋜⋝⋞⋟⋠⋡⋢⋣⋤⋥⋦⋧⋨⋩⋪⋫⋬⋭⋲⋳⋴⋵⋶⋷⋸⋹⋺⋻⋼⋽⋾⋿⟈⟉⟒⦷⧀⧁⧡⧣⧤⧥⩦⩧⩪⩫⩬⩭⩮⩯⩰⩱⩲⩳⩴⩵⩶⩷⩸⩹⩺⩻⩼⩽⩾⩿⪀⪁⪂⪃⪄⪅⪆⪇⪈⪉⪊⪋⪌⪍⪎⪏⪐⪑⪒⪓⪔⪕⪖⪗⪘⪙⪚⪛⪜⪝⪞⪟⪠⪡⪢⪣⪤⪥⪦⪧⪨⪩⪪⪫⪬⪭⪮⪯⪰⪱⪲⪳⪴⪵⪶⪷⪸⪹⪺⪻⪼⪽⪾⪿⫀⫁⫂⫃⫄⫅⫆⫇⫈⫉⫊⫋⫌⫍⫎⫏⫐⫑⫒⫓⫔⫕⫖⫗⫘⫙⫷⫸⫹⫺⊢⊣" .
|
||||||
" \ "⊔∓∔∸≂≏⊎⊽⋎⋓⧺⧻⨈⨢⨣⨤⨥⨦⨧⨨⨩⨪⨫⨬⨭⨮⨹⨺⩁⩂⩅⩊⩌⩏⩐⩒⩔⩖⩗⩛⩝⩡⩢⩣" .
|
" \ "⊔∓∔∸≂≏⊎⊽⋎⋓⧺⧻⨈⨢⨣⨤⨥⨦⨧⨨⨩⨪⨫⨬⨭⨮⨹⨺⩁⩂⩅⩊⩌⩏⩐⩒⩔⩖⩗⩛⩝⩡⩢⩣" .
|
||||||
" \ "⊙⊚⊛⊡⊓∗∙∤⅋≀⊼⋄⋆⋇⋉⋊⋋⋌⋏⋒⟑⦸⦼⦾⦿⧶⧷⨇⨰⨱⨲⨳⨴⨵⨶⨷⨸⨻⨼⨽⩀⩃⩄⩋⩍⩎⩑⩓⩕⩘⩚⩜⩞⩟⩠⫛⊍▷⨝⟕⟖⟗" .
|
" \ "⊙⊚⊛⊡⊓∗∙∤⅋≀⊼⋄⋇⋉⋊⋋⋌⋏⋒⟑⦸⦼⦾⦿⧶⧷⨇⨰⨱⨲⨳⨴⨵⨶⨷⨸⨻⨼⨽⩀⩃⩄⩋⩍⩎⩑⩓⩕⩘⩚⩜⩞⩟⩠⫛⊍▷⨝⟕⟖⟗" .
|
||||||
" \ "⇵⟰⟱⤈⤉⤊⤋⤒⤓⥉⥌⥍⥏⥑⥔⥕⥘⥙⥜⥝⥠⥡⥣⥥⥮⥯↑↓"
|
" \ "⇵⟰⟱⤈⤉⤊⤋⤒⤓⥉⥌⥍⥏⥑⥔⥕⥘⥙⥜⥝⥠⥡⥣⥥⥮⥯↑↓"
|
||||||
|
|
||||||
" same as above, but with character ranges, for performance
|
" same as above, but with character ranges, for performance
|
||||||
|
|||||||
@@ -1,142 +0,0 @@
|
|||||||
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'liquid') != -1
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
" Vim syntax file
|
|
||||||
" Language: Liquid
|
|
||||||
" Maintainer: Tim Pope <vimNOSPAM@tpope.org>
|
|
||||||
" Filenames: *.liquid
|
|
||||||
" Last Change: 2010 May 21
|
|
||||||
|
|
||||||
if exists('b:current_syntax')
|
|
||||||
finish
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('main_syntax')
|
|
||||||
let main_syntax = 'liquid'
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('g:liquid_default_subtype')
|
|
||||||
let g:liquid_default_subtype = 'html'
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('b:liquid_subtype') && main_syntax == 'liquid'
|
|
||||||
let s:lines = getline(1)."\n".getline(2)."\n".getline(3)."\n".getline(4)."\n".getline(5)."\n".getline("$")
|
|
||||||
let b:liquid_subtype = matchstr(s:lines,'liquid_subtype=\zs\w\+')
|
|
||||||
if b:liquid_subtype == ''
|
|
||||||
let b:liquid_subtype = matchstr(&filetype,'^liquid\.\zs\w\+')
|
|
||||||
endif
|
|
||||||
if b:liquid_subtype == ''
|
|
||||||
let b:liquid_subtype = matchstr(substitute(expand('%:t'),'\c\%(\.liquid\)\+$','',''),'\.\zs\w\+$')
|
|
||||||
endif
|
|
||||||
if b:liquid_subtype == ''
|
|
||||||
let b:liquid_subtype = g:liquid_default_subtype
|
|
||||||
endif
|
|
||||||
endif
|
|
||||||
|
|
||||||
if exists('b:liquid_subtype') && b:liquid_subtype != ''
|
|
||||||
exe 'runtime! syntax/'.b:liquid_subtype.'.vim'
|
|
||||||
unlet! b:current_syntax
|
|
||||||
endif
|
|
||||||
|
|
||||||
syn case match
|
|
||||||
|
|
||||||
if exists('b:liquid_subtype') && b:liquid_subtype != 'yaml'
|
|
||||||
" YAML Front Matter
|
|
||||||
syn include @liquidYamlTop syntax/yaml.vim
|
|
||||||
unlet! b:current_syntax
|
|
||||||
syn region liquidYamlHead start="\%^---$" end="^---\s*$" keepend contains=@liquidYamlTop,@Spell
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('g:liquid_highlight_types')
|
|
||||||
let g:liquid_highlight_types = []
|
|
||||||
endif
|
|
||||||
|
|
||||||
if !exists('s:subtype')
|
|
||||||
let s:subtype = exists('b:liquid_subtype') ? b:liquid_subtype : ''
|
|
||||||
|
|
||||||
for s:type in map(copy(g:liquid_highlight_types),'matchstr(v:val,"[^=]*$")')
|
|
||||||
if s:type =~ '\.'
|
|
||||||
let b:{matchstr(s:type,'[^.]*')}_subtype = matchstr(s:type,'\.\zs.*')
|
|
||||||
endif
|
|
||||||
exe 'syn include @liquidHighlight'.substitute(s:type,'\.','','g').' syntax/'.matchstr(s:type,'[^.]*').'.vim'
|
|
||||||
unlet! b:current_syntax
|
|
||||||
endfor
|
|
||||||
unlet! s:type
|
|
||||||
|
|
||||||
if s:subtype == ''
|
|
||||||
unlet! b:liquid_subtype
|
|
||||||
else
|
|
||||||
let b:liquid_subtype = s:subtype
|
|
||||||
endif
|
|
||||||
unlet s:subtype
|
|
||||||
endif
|
|
||||||
|
|
||||||
syn region liquidStatement matchgroup=liquidDelimiter start="{%" end="%}" contains=@liquidStatement containedin=ALLBUT,@liquidExempt keepend
|
|
||||||
syn region liquidExpression matchgroup=liquidDelimiter start="{{" end="}}" contains=@liquidExpression containedin=ALLBUT,@liquidExempt keepend
|
|
||||||
syn region liquidComment matchgroup=liquidDelimiter start="{%\s*comment\s*%}" end="{%\s*endcomment\s*%}" contains=liquidTodo,@Spell containedin=ALLBUT,@liquidExempt keepend
|
|
||||||
syn region liquidRaw matchgroup=liquidDelimiter start="{%\s*raw\s*%}" end="{%\s*endraw\s*%}" contains=TOP,@liquidExempt containedin=ALLBUT,@liquidExempt keepend
|
|
||||||
|
|
||||||
syn cluster liquidExempt contains=liquidStatement,liquidExpression,liquidComment,liquidRaw,@liquidStatement,liquidYamlHead
|
|
||||||
syn cluster liquidStatement contains=liquidConditional,liquidRepeat,liquidKeyword,@liquidExpression
|
|
||||||
syn cluster liquidExpression contains=liquidOperator,liquidString,liquidNumber,liquidFloat,liquidBoolean,liquidNull,liquidEmpty,liquidPipe,liquidForloop
|
|
||||||
|
|
||||||
syn keyword liquidKeyword highlight nextgroup=liquidTypeHighlight skipwhite contained
|
|
||||||
syn keyword liquidKeyword endhighlight contained
|
|
||||||
syn region liquidHighlight start="{%\s*highlight\s\+\w\+\s*%}" end="{% endhighlight %}" keepend
|
|
||||||
|
|
||||||
for s:type in g:liquid_highlight_types
|
|
||||||
exe 'syn match liquidTypeHighlight "\<'.matchstr(s:type,'[^=]*').'\>" contained'
|
|
||||||
exe 'syn region liquidHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\..*','','').' start="{%\s*highlight\s\+'.matchstr(s:type,'[^=]*').'\s*%}" end="{% endhighlight %}" keepend contains=@liquidHighlight'.substitute(matchstr(s:type,'[^=]*$'),'\.','','g')
|
|
||||||
endfor
|
|
||||||
unlet! s:type
|
|
||||||
|
|
||||||
syn region liquidString matchgroup=liquidQuote start=+"+ end=+"+ contained
|
|
||||||
syn region liquidString matchgroup=liquidQuote start=+'+ end=+'+ contained
|
|
||||||
syn match liquidNumber "-\=\<\d\+\>" contained
|
|
||||||
syn match liquidFloat "-\=\<\d\+\>\.\.\@!\%(\d\+\>\)\=" contained
|
|
||||||
syn keyword liquidBoolean true false contained
|
|
||||||
syn keyword liquidNull null nil contained
|
|
||||||
syn match liquidEmpty "\<empty\>" contained
|
|
||||||
|
|
||||||
syn keyword liquidOperator and or not contained
|
|
||||||
syn match liquidPipe '|' contained skipwhite nextgroup=liquidFilter
|
|
||||||
|
|
||||||
syn keyword liquidFilter date capitalize downcase upcase first last join sort size strip_html strip_newlines newline_to_br replace replace_first remove remove_first truncate truncatewords prepend append minus plus times divided_by contained
|
|
||||||
|
|
||||||
syn keyword liquidConditional if elsif else endif unless endunless case when endcase ifchanged endifchanged contained
|
|
||||||
syn keyword liquidRepeat for endfor tablerow endtablerow in contained
|
|
||||||
syn match liquidRepeat "\%({%\s*\)\@<=empty\>" contained
|
|
||||||
syn keyword liquidKeyword assign cycle include with contained
|
|
||||||
|
|
||||||
syn keyword liquidForloop forloop nextgroup=liquidForloopDot contained
|
|
||||||
syn match liquidForloopDot "\." nextgroup=liquidForloopAttribute contained
|
|
||||||
syn keyword liquidForloopAttribute length index index0 rindex rindex0 first last contained
|
|
||||||
|
|
||||||
syn keyword liquidTablerowloop tablerowloop nextgroup=liquidTablerowloopDot contained
|
|
||||||
syn match liquidTablerowloopDot "\." nextgroup=liquidTableForloopAttribute contained
|
|
||||||
syn keyword liquidTablerowloopAttribute length index index0 col col0 index0 rindex rindex0 first last col_first col_last contained
|
|
||||||
|
|
||||||
hi def link liquidDelimiter PreProc
|
|
||||||
hi def link liquidComment Comment
|
|
||||||
hi def link liquidTypeHighlight Type
|
|
||||||
hi def link liquidConditional Conditional
|
|
||||||
hi def link liquidRepeat Repeat
|
|
||||||
hi def link liquidKeyword Keyword
|
|
||||||
hi def link liquidOperator Operator
|
|
||||||
hi def link liquidString String
|
|
||||||
hi def link liquidQuote Delimiter
|
|
||||||
hi def link liquidNumber Number
|
|
||||||
hi def link liquidFloat Float
|
|
||||||
hi def link liquidEmpty liquidNull
|
|
||||||
hi def link liquidNull liquidBoolean
|
|
||||||
hi def link liquidBoolean Boolean
|
|
||||||
hi def link liquidFilter Function
|
|
||||||
hi def link liquidForloop Identifier
|
|
||||||
hi def link liquidForloopAttribute Identifier
|
|
||||||
|
|
||||||
let b:current_syntax = 'liquid'
|
|
||||||
|
|
||||||
if exists('main_syntax') && main_syntax == 'liquid'
|
|
||||||
unlet main_syntax
|
|
||||||
endif
|
|
||||||
237
syntax/llvm.vim
Normal file
237
syntax/llvm.vim
Normal file
@@ -0,0 +1,237 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim syntax file
|
||||||
|
" Language: llvm
|
||||||
|
" Maintainer: The LLVM team, http://llvm.org/
|
||||||
|
" Version: $Revision$
|
||||||
|
|
||||||
|
if version < 600
|
||||||
|
syntax clear
|
||||||
|
elseif exists("b:current_syntax")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
syn case match
|
||||||
|
|
||||||
|
" Types.
|
||||||
|
" Types also include struct, array, vector, etc. but these don't
|
||||||
|
" benefit as much from having dedicated highlighting rules.
|
||||||
|
syn keyword llvmType void half float double x86_fp80 fp128 ppc_fp128
|
||||||
|
syn keyword llvmType label metadata x86_mmx
|
||||||
|
syn keyword llvmType type label opaque token
|
||||||
|
syn match llvmType /\<i\d\+\>/
|
||||||
|
|
||||||
|
" Instructions.
|
||||||
|
" The true and false tokens can be used for comparison opcodes, but it's
|
||||||
|
" much more common for these tokens to be used for boolean constants.
|
||||||
|
syn keyword llvmStatement add addrspacecast alloca and arcp ashr atomicrmw
|
||||||
|
syn keyword llvmStatement bitcast br catchpad catchswitch catchret call
|
||||||
|
syn keyword llvmStatement cleanuppad cleanupret cmpxchg eq exact extractelement
|
||||||
|
syn keyword llvmStatement extractvalue fadd fast fcmp fdiv fence fmul fpext
|
||||||
|
syn keyword llvmStatement fptosi fptoui fptrunc free frem fsub getelementptr
|
||||||
|
syn keyword llvmStatement icmp inbounds indirectbr insertelement insertvalue
|
||||||
|
syn keyword llvmStatement inttoptr invoke landingpad load lshr malloc max min
|
||||||
|
syn keyword llvmStatement mul nand ne ninf nnan nsw nsz nuw oeq oge ogt ole
|
||||||
|
syn keyword llvmStatement olt one or ord phi ptrtoint resume ret sdiv select
|
||||||
|
syn keyword llvmStatement sext sge sgt shl shufflevector sitofp sle slt srem
|
||||||
|
syn keyword llvmStatement store sub switch trunc udiv ueq uge ugt uitofp ule ult
|
||||||
|
syn keyword llvmStatement umax umin une uno unreachable unwind urem va_arg
|
||||||
|
syn keyword llvmStatement xchg xor zext
|
||||||
|
|
||||||
|
" Keywords.
|
||||||
|
syn keyword llvmKeyword
|
||||||
|
\ acq_rel
|
||||||
|
\ acquire
|
||||||
|
\ addrspace
|
||||||
|
\ alias
|
||||||
|
\ align
|
||||||
|
\ alignstack
|
||||||
|
\ alwaysinline
|
||||||
|
\ appending
|
||||||
|
\ argmemonly
|
||||||
|
\ arm_aapcscc
|
||||||
|
\ arm_aapcs_vfpcc
|
||||||
|
\ arm_apcscc
|
||||||
|
\ asm
|
||||||
|
\ atomic
|
||||||
|
\ available_externally
|
||||||
|
\ blockaddress
|
||||||
|
\ builtin
|
||||||
|
\ byval
|
||||||
|
\ c
|
||||||
|
\ catch
|
||||||
|
\ caller
|
||||||
|
\ cc
|
||||||
|
\ ccc
|
||||||
|
\ cleanup
|
||||||
|
\ coldcc
|
||||||
|
\ comdat
|
||||||
|
\ common
|
||||||
|
\ constant
|
||||||
|
\ datalayout
|
||||||
|
\ declare
|
||||||
|
\ default
|
||||||
|
\ define
|
||||||
|
\ deplibs
|
||||||
|
\ dereferenceable
|
||||||
|
\ distinct
|
||||||
|
\ dllexport
|
||||||
|
\ dllimport
|
||||||
|
\ dso_local
|
||||||
|
\ dso_preemptable
|
||||||
|
\ except
|
||||||
|
\ external
|
||||||
|
\ externally_initialized
|
||||||
|
\ extern_weak
|
||||||
|
\ fastcc
|
||||||
|
\ filter
|
||||||
|
\ from
|
||||||
|
\ gc
|
||||||
|
\ global
|
||||||
|
\ hhvmcc
|
||||||
|
\ hhvm_ccc
|
||||||
|
\ hidden
|
||||||
|
\ initialexec
|
||||||
|
\ inlinehint
|
||||||
|
\ inreg
|
||||||
|
\ inteldialect
|
||||||
|
\ intel_ocl_bicc
|
||||||
|
\ internal
|
||||||
|
\ linkonce
|
||||||
|
\ linkonce_odr
|
||||||
|
\ localdynamic
|
||||||
|
\ localexec
|
||||||
|
\ local_unnamed_addr
|
||||||
|
\ minsize
|
||||||
|
\ module
|
||||||
|
\ monotonic
|
||||||
|
\ msp430_intrcc
|
||||||
|
\ musttail
|
||||||
|
\ naked
|
||||||
|
\ nest
|
||||||
|
\ noalias
|
||||||
|
\ nobuiltin
|
||||||
|
\ nocapture
|
||||||
|
\ noimplicitfloat
|
||||||
|
\ noinline
|
||||||
|
\ nonlazybind
|
||||||
|
\ nonnull
|
||||||
|
\ norecurse
|
||||||
|
\ noredzone
|
||||||
|
\ noreturn
|
||||||
|
\ nounwind
|
||||||
|
\ optnone
|
||||||
|
\ optsize
|
||||||
|
\ personality
|
||||||
|
\ private
|
||||||
|
\ protected
|
||||||
|
\ ptx_device
|
||||||
|
\ ptx_kernel
|
||||||
|
\ readnone
|
||||||
|
\ readonly
|
||||||
|
\ release
|
||||||
|
\ returned
|
||||||
|
\ returns_twice
|
||||||
|
\ sanitize_address
|
||||||
|
\ sanitize_memory
|
||||||
|
\ sanitize_thread
|
||||||
|
\ section
|
||||||
|
\ seq_cst
|
||||||
|
\ sideeffect
|
||||||
|
\ signext
|
||||||
|
\ syncscope
|
||||||
|
\ source_filename
|
||||||
|
\ speculatable
|
||||||
|
\ spir_func
|
||||||
|
\ spir_kernel
|
||||||
|
\ sret
|
||||||
|
\ ssp
|
||||||
|
\ sspreq
|
||||||
|
\ sspstrong
|
||||||
|
\ strictfp
|
||||||
|
\ swiftcc
|
||||||
|
\ tail
|
||||||
|
\ target
|
||||||
|
\ thread_local
|
||||||
|
\ to
|
||||||
|
\ triple
|
||||||
|
\ unnamed_addr
|
||||||
|
\ unordered
|
||||||
|
\ uselistorder
|
||||||
|
\ uselistorder_bb
|
||||||
|
\ uwtable
|
||||||
|
\ volatile
|
||||||
|
\ weak
|
||||||
|
\ weak_odr
|
||||||
|
\ within
|
||||||
|
\ writeonly
|
||||||
|
\ x86_64_sysvcc
|
||||||
|
\ win64cc
|
||||||
|
\ x86_fastcallcc
|
||||||
|
\ x86_stdcallcc
|
||||||
|
\ x86_thiscallcc
|
||||||
|
\ zeroext
|
||||||
|
|
||||||
|
" Obsolete keywords.
|
||||||
|
syn keyword llvmError getresult begin end
|
||||||
|
|
||||||
|
" Misc syntax.
|
||||||
|
syn match llvmNoName /[%@!]\d\+\>/
|
||||||
|
syn match llvmNumber /-\?\<\d\+\>/
|
||||||
|
syn match llvmFloat /-\?\<\d\+\.\d*\(e[+-]\d\+\)\?\>/
|
||||||
|
syn match llvmFloat /\<0x\x\+\>/
|
||||||
|
syn keyword llvmBoolean true false
|
||||||
|
syn keyword llvmConstant zeroinitializer undef null none
|
||||||
|
syn match llvmComment /;.*$/
|
||||||
|
syn region llvmString start=/"/ skip=/\\"/ end=/"/
|
||||||
|
syn match llvmLabel /[-a-zA-Z$._][-a-zA-Z$._0-9]*:/
|
||||||
|
syn match llvmIdentifier /[%@][-a-zA-Z$._][-a-zA-Z$._0-9]*/
|
||||||
|
|
||||||
|
" Named metadata and specialized metadata keywords.
|
||||||
|
syn match llvmIdentifier /![-a-zA-Z$._][-a-zA-Z$._0-9]*\ze\s*$/
|
||||||
|
syn match llvmIdentifier /![-a-zA-Z$._][-a-zA-Z$._0-9]*\ze\s*[=!]/
|
||||||
|
syn match llvmType /!\zs\a\+\ze\s*(/
|
||||||
|
syn match llvmConstant /\<DW_TAG_[a-z_]\+\>/
|
||||||
|
syn match llvmConstant /\<DW_ATE_[a-zA-Z_]\+\>/
|
||||||
|
syn match llvmConstant /\<DW_OP_[a-zA-Z0-9_]\+\>/
|
||||||
|
syn match llvmConstant /\<DW_LANG_[a-zA-Z0-9_]\+\>/
|
||||||
|
syn match llvmConstant /\<DW_VIRTUALITY_[a-z_]\+\>/
|
||||||
|
syn match llvmConstant /\<DIFlag[A-Za-z]\+\>/
|
||||||
|
|
||||||
|
" Syntax-highlight lit test commands and bug numbers.
|
||||||
|
syn match llvmSpecialComment /;\s*PR\d*\s*$/
|
||||||
|
syn match llvmSpecialComment /;\s*REQUIRES:.*$/
|
||||||
|
syn match llvmSpecialComment /;\s*RUN:.*$/
|
||||||
|
syn match llvmSpecialComment /;\s*CHECK:.*$/
|
||||||
|
syn match llvmSpecialComment "\v;\s*CHECK-(NEXT|NOT|DAG|SAME|LABEL):.*$"
|
||||||
|
syn match llvmSpecialComment /;\s*XFAIL:.*$/
|
||||||
|
|
||||||
|
if version >= 508 || !exists("did_c_syn_inits")
|
||||||
|
if version < 508
|
||||||
|
let did_c_syn_inits = 1
|
||||||
|
command -nargs=+ HiLink hi link <args>
|
||||||
|
else
|
||||||
|
command -nargs=+ HiLink hi def link <args>
|
||||||
|
endif
|
||||||
|
|
||||||
|
HiLink llvmType Type
|
||||||
|
HiLink llvmStatement Statement
|
||||||
|
HiLink llvmNumber Number
|
||||||
|
HiLink llvmComment Comment
|
||||||
|
HiLink llvmString String
|
||||||
|
HiLink llvmLabel Label
|
||||||
|
HiLink llvmKeyword Keyword
|
||||||
|
HiLink llvmBoolean Boolean
|
||||||
|
HiLink llvmFloat Float
|
||||||
|
HiLink llvmNoName Identifier
|
||||||
|
HiLink llvmConstant Constant
|
||||||
|
HiLink llvmSpecialComment SpecialComment
|
||||||
|
HiLink llvmError Error
|
||||||
|
HiLink llvmIdentifier Identifier
|
||||||
|
|
||||||
|
delcommand HiLink
|
||||||
|
endif
|
||||||
|
|
||||||
|
let b:current_syntax = "llvm"
|
||||||
@@ -103,7 +103,7 @@ syn match htmlH2 /^.\+\n-\+$/ contains=mkdLink,mkdInlineURL,@Spell
|
|||||||
syn match mkdLineBreak / \+$/
|
syn match mkdLineBreak / \+$/
|
||||||
syn region mkdBlockquote start=/^\s*>/ end=/$/ contains=mkdLink,mkdInlineURL,mkdLineBreak,@Spell
|
syn region mkdBlockquote start=/^\s*>/ end=/$/ contains=mkdLink,mkdInlineURL,mkdLineBreak,@Spell
|
||||||
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/\(\([^\\]\|^\)\\\)\@<!`/ end=/`/' . s:concealcode
|
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/\(\([^\\]\|^\)\\\)\@<!`/ end=/`/' . s:concealcode
|
||||||
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/\(\([^\\]\|^\)\\\)\@<!``/ skip=/[^`]`[^`]/ end=/\(\([^\\]\|^\)\\\)\@<!``/' . s:concealcode
|
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/\(\([^\\]\|^\)\\\)\@<!``/ skip=/[^`]`[^`]/ end=/``/' . s:concealcode
|
||||||
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/^\s*\z(`\{3,}\)[^`]*$/ end=/^\s*\z1`*\s*$/' . s:concealcode
|
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/^\s*\z(`\{3,}\)[^`]*$/ end=/^\s*\z1`*\s*$/' . s:concealcode
|
||||||
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/\(\([^\\]\|^\)\\\)\@<!\~\~/ end=/\(\([^\\]\|^\)\\\)\@<!\~\~/' . s:concealcode
|
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/\(\([^\\]\|^\)\\\)\@<!\~\~/ end=/\(\([^\\]\|^\)\\\)\@<!\~\~/' . s:concealcode
|
||||||
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/^\s*\z(\~\{3,}\)\s*[0-9A-Za-z_+-]*\s*$/ end=/^\s*\z1\~*\s*$/' . s:concealcode
|
execute 'syn region mkdCode matchgroup=mkdCodeDelimiter start=/^\s*\z(\~\{3,}\)\s*[0-9A-Za-z_+-]*\s*$/ end=/^\s*\z1\~*\s*$/' . s:concealcode
|
||||||
|
|||||||
1473
syntax/mma.vim
1473
syntax/mma.vim
File diff suppressed because it is too large
Load Diff
4200
syntax/pgsql.vim
4200
syntax/pgsql.vim
File diff suppressed because it is too large
Load Diff
File diff suppressed because one or more lines are too long
336
syntax/ruby.vim
336
syntax/ruby.vim
@@ -68,9 +68,8 @@ endfunction
|
|||||||
|
|
||||||
com! -nargs=* SynFold call s:run_syntax_fold(<q-args>)
|
com! -nargs=* SynFold call s:run_syntax_fold(<q-args>)
|
||||||
|
|
||||||
" }}}
|
" Not-Top Cluster {{{1
|
||||||
|
syn cluster rubyNotTop contains=@rubyCommentNotTop,@rubyStringNotTop,@rubyRegexpSpecial,@rubyDeclaration,@rubyExceptionHandler,@rubyClassOperator,rubyConditional,rubyModuleName,rubyClassName,rubySymbolDelimiter,rubyParentheses
|
||||||
syn cluster rubyNotTop contains=@rubyCommentNotTop,@rubyStringNotTop,@rubyRegexpSpecial,@rubyDeclaration,@rubyExceptionHandler,rubyConditional,rubyModuleName,rubyClassName,rubySymbolDelimiter
|
|
||||||
|
|
||||||
" Whitespace Errors {{{1
|
" Whitespace Errors {{{1
|
||||||
if exists("ruby_space_errors")
|
if exists("ruby_space_errors")
|
||||||
@@ -83,20 +82,39 @@ if exists("ruby_space_errors")
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
" Operators {{{1
|
" Operators {{{1
|
||||||
if exists("ruby_operators")
|
|
||||||
syn match rubyDotOperator "\.\|&\." containedin=rubyKeywordAsMethod
|
|
||||||
syn match rubyTernaryOperator "[[:alnum:]]\@1<!?\|:"
|
|
||||||
syn match rubyArithmeticOperator "\*\*\|[*/%+]\|->\@!"
|
|
||||||
syn match rubyComparisonOperator "<=>\|<=\|\%(<\|\<class\s\+\u\w*\s*\)\@<!<<\@!\|>=\|[-=]\@1<!>"
|
|
||||||
syn match rubyBitwiseOperator "[~^|]\|&\.\@!\|\%(class\s*\)\@<!<<\|>>"
|
|
||||||
syn match rubyBooleanOperator "[[:alnum:]]\@1<!!\|&&\|||"
|
|
||||||
syn match rubyRangeOperator "\.\.\.\="
|
|
||||||
syn match rubyAssignmentOperator "=>\@!\|-=\|/=\|\*\*=\|\*=\|&&=\|&=\|||=\||=\|%=\|+=\|>>=\|<<=\|\^="
|
|
||||||
syn match rubyEqualityOperator "===\|==\|!=\|!\~\|=\~"
|
|
||||||
syn match rubyScopeOperator "::"
|
|
||||||
syn region rubyBracketOperator matchgroup=rubyOperator start="\%(\w[?!]\=\|[]})]\)\@2<=\[\s*" end="\s*]" contains=ALLBUT,@rubyNotTop
|
|
||||||
|
|
||||||
syn cluster rubyOperator contains=ruby.*Operator
|
syn match rubyEnglishBooleanOperator "\<\%(and\|or\|not\)\>"
|
||||||
|
|
||||||
|
if exists("ruby_operators") || exists("ruby_pseudo_operators")
|
||||||
|
syn match rubyDotOperator "\.\|&\."
|
||||||
|
|
||||||
|
syn match rubyTernaryOperator "\%(\w\|[^\x00-\x7F]\)\@1<!?\|:"
|
||||||
|
syn match rubyArithmeticOperator "\*\*\|[*/%+]\|->\@!"
|
||||||
|
syn match rubyComparisonOperator "<=>\|<=\|<\|>=\|[-=]\@1<!>"
|
||||||
|
syn match rubyBitwiseOperator "[~^|]\|&\.\@!\|<<\|>>"
|
||||||
|
syn match rubyBooleanOperator "\%(\w\|[^\x00-\x7F]\)\@1<!!\|&&\|||"
|
||||||
|
syn match rubyRangeOperator "\.\.\.\="
|
||||||
|
syn match rubyAssignmentOperator "=>\@!\|-=\|/=\|\*\*=\|\*=\|&&=\|&=\|||=\||=\|%=\|+=\|>>=\|<<=\|\^="
|
||||||
|
syn match rubyAssignmentOperator "=>\@!" containedin=rubyBlockParameterList " TODO: this is inelegant
|
||||||
|
syn match rubyEqualityOperator "===\|==\|!=\|!\~\|=\~"
|
||||||
|
|
||||||
|
syn region rubyBracketOperator matchgroup=rubyOperator start="\%(\%(\w\|[^\x00-\x7F]\)[?!]\=\|[]})]\)\@2<=\[" end="]" contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
|
syn match rubyScopeOperator "::"
|
||||||
|
syn match rubySuperClassOperator "<" contained
|
||||||
|
syn match rubyEigenClassOperator "<<" contained
|
||||||
|
syn match rubyLambdaOperator "->"
|
||||||
|
syn match rubySplatOperator "\%([[{(|,=]\_s*\)\@<=\*"
|
||||||
|
syn match rubySplatOperator "\%(^\|\s\)\@1<=\*\%(\h\|[^\x00-\x7F]\|[:$@[]\)\@="
|
||||||
|
syn match rubyDoubleSplatOperator "\%([{(|,]\_s*\)\@<=\*\*"
|
||||||
|
syn match rubyDoubleSplatOperator "\s\@1<=\*\*\%(\h\|[^\x00-\x7F]\|[:$@{]\)\@="
|
||||||
|
syn match rubyProcOperator "\%([[(|,]\_s*\)\@<=&"
|
||||||
|
syn match rubyProcOperator "\s\@1<=&\%(\h\|[^\x00-\x7F]\|[:$@]\|->\)\@="
|
||||||
|
|
||||||
|
syn cluster rubyProperOperator contains=rubyTernaryOperator,rubyArithmeticOperator,rubyComparisonOperator,rubyBitwiseOperator,rubyBooleanOperator,rubyRangeOperator,rubyAssignmentOperator,rubyEqualityOperator,rubyDefinedOperator,rubyEnglishBooleanOperator
|
||||||
|
syn cluster rubyClassOperator contains=rubyEigenClassOperator,rubySuperClassOperator
|
||||||
|
syn cluster rubyPseudoOperator contains=rubyDotOperator,rubyScopeOperator,rubyEigenClassOperator,rubySuperClassOperator,rubyLambdaOperator,rubySplatOperator,rubyDoubleSplatOperator,rubyProcOperator
|
||||||
|
syn cluster rubyOperator contains=ruby.*Operator
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" String Interpolation and Backslash Notation {{{1
|
" String Interpolation and Backslash Notation {{{1
|
||||||
@@ -105,26 +123,26 @@ syn match rubyInterpolation "#\$\%(-\w\|[!$&"'*+,./0:;<>?@\`~_]\|\w\+\)"
|
|||||||
syn match rubyInterpolation "#@@\=\w\+" display contained contains=rubyInterpolationDelimiter,rubyInstanceVariable,rubyClassVariable
|
syn match rubyInterpolation "#@@\=\w\+" display contained contains=rubyInterpolationDelimiter,rubyInstanceVariable,rubyClassVariable
|
||||||
syn match rubyInterpolationDelimiter "#\ze[$@]" display contained
|
syn match rubyInterpolationDelimiter "#\ze[$@]" display contained
|
||||||
|
|
||||||
syn match rubyStringEscape "\\\_." contained display
|
syn match rubyStringEscape "\\\_." contained display
|
||||||
syn match rubyStringEscape "\\\o\{1,3}\|\\x\x\{1,2}" contained display
|
syn match rubyStringEscape "\\\o\{1,3}\|\\x\x\{1,2}" contained display
|
||||||
syn match rubyStringEscape "\\u\%(\x\{4}\|{\x\{1,6}\%(\s\+\x\{1,6}\)*}\)" contained display
|
syn match rubyStringEscape "\\u\%(\x\{4}\|{\x\{1,6}\%(\s\+\x\{1,6}\)*}\)" contained display
|
||||||
syn match rubyStringEscape "\%(\\M-\\C-\|\\C-\\M-\|\\M-\\c\|\\c\\M-\|\\c\|\\C-\|\\M-\)\%(\\\o\{1,3}\|\\x\x\{1,2}\|\\\=\S\)" contained display
|
syn match rubyStringEscape "\%(\\M-\\C-\|\\C-\\M-\|\\M-\\c\|\\c\\M-\|\\c\|\\C-\|\\M-\)\%(\\\o\{1,3}\|\\x\x\{1,2}\|\\\=.\)" contained display
|
||||||
|
|
||||||
syn match rubyBackslashEscape "\\\\" contained display
|
syn match rubyBackslashEscape "\\\\" contained display
|
||||||
syn match rubyQuoteEscape "\\'" contained display
|
syn match rubyQuoteEscape "\\'" contained display
|
||||||
syn match rubySpaceEscape "\\ " contained display
|
syn match rubySpaceEscape "\\ " contained display
|
||||||
|
|
||||||
syn match rubyParenthesesEscape "\\[()]" contained display
|
syn match rubyParenthesisEscape "\\[()]" contained display
|
||||||
syn match rubyCurlyBracesEscape "\\[{}]" contained display
|
syn match rubyCurlyBraceEscape "\\[{}]" contained display
|
||||||
syn match rubyAngleBracketsEscape "\\[<>]" contained display
|
syn match rubyAngleBracketEscape "\\[<>]" contained display
|
||||||
syn match rubySquareBracketsEscape "\\[[\]]" contained display
|
syn match rubySquareBracketEscape "\\[[\]]" contained display
|
||||||
|
|
||||||
syn region rubyNestedParentheses start="(" skip="\\\\\|\\)" matchgroup=rubyString end=")" transparent contained
|
syn region rubyNestedParentheses start="(" skip="\\\\\|\\)" matchgroup=rubyString end=")" transparent contained
|
||||||
syn region rubyNestedCurlyBraces start="{" skip="\\\\\|\\}" matchgroup=rubyString end="}" transparent contained
|
syn region rubyNestedCurlyBraces start="{" skip="\\\\\|\\}" matchgroup=rubyString end="}" transparent contained
|
||||||
syn region rubyNestedAngleBrackets start="<" skip="\\\\\|\\>" matchgroup=rubyString end=">" transparent contained
|
syn region rubyNestedAngleBrackets start="<" skip="\\\\\|\\>" matchgroup=rubyString end=">" transparent contained
|
||||||
syn region rubyNestedSquareBrackets start="\[" skip="\\\\\|\\\]" matchgroup=rubyString end="\]" transparent contained
|
syn region rubyNestedSquareBrackets start="\[" skip="\\\\\|\\\]" matchgroup=rubyString end="\]" transparent contained
|
||||||
|
|
||||||
syn cluster rubySingleCharEscape contains=rubyBackslashEscape,rubyQuoteEscape,rubySpaceEscape,rubyParenthesesEscape,rubyCurlyBracesEscape,rubyAngleBracketsEscape,rubySquareBracketsEscape
|
syn cluster rubySingleCharEscape contains=rubyBackslashEscape,rubyQuoteEscape,rubySpaceEscape,rubyParenthesisEscape,rubyCurlyBraceEscape,rubyAngleBracketEscape,rubySquareBracketEscape
|
||||||
syn cluster rubyNestedBrackets contains=rubyNested.\+
|
syn cluster rubyNestedBrackets contains=rubyNested.\+
|
||||||
syn cluster rubyStringSpecial contains=rubyInterpolation,rubyStringEscape
|
syn cluster rubyStringSpecial contains=rubyInterpolation,rubyStringEscape
|
||||||
syn cluster rubyStringNotTop contains=@rubyStringSpecial,@rubyNestedBrackets,@rubySingleCharEscape
|
syn cluster rubyStringNotTop contains=@rubyStringSpecial,@rubyNestedBrackets,@rubySingleCharEscape
|
||||||
@@ -153,20 +171,17 @@ syn match rubyRegexpSpecial "\\g'\%([a-z_]\w*\|-\=\d\+\)'" contained display
|
|||||||
syn cluster rubyRegexpSpecial contains=@rubyStringSpecial,rubyRegexpSpecial,rubyRegexpEscape,rubyRegexpBrackets,rubyRegexpCharClass,rubyRegexpDot,rubyRegexpQuantifier,rubyRegexpAnchor,rubyRegexpParens,rubyRegexpComment,rubyRegexpIntersection
|
syn cluster rubyRegexpSpecial contains=@rubyStringSpecial,rubyRegexpSpecial,rubyRegexpEscape,rubyRegexpBrackets,rubyRegexpCharClass,rubyRegexpDot,rubyRegexpQuantifier,rubyRegexpAnchor,rubyRegexpParens,rubyRegexpComment,rubyRegexpIntersection
|
||||||
|
|
||||||
" Numbers {{{1
|
" Numbers {{{1
|
||||||
syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<0[xX]\x\+\%(_\x\+\)*r\=i\=\>" display
|
syn match rubyInteger "\%(\%(\w\|[^\x00-\x7F]\|[]})\"']\s*\)\@<!-\)\=\<0[xX]\x\+\%(_\x\+\)*r\=i\=\>" display
|
||||||
syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<\%(0[dD]\)\=\%(0\|[1-9]\d*\%(_\d\+\)*\)r\=i\=\>" display
|
syn match rubyInteger "\%(\%(\w\|[^\x00-\x7F]\|[]})\"']\s*\)\@<!-\)\=\<\%(0[dD]\)\=\%(0\|[1-9]\d*\%(_\d\+\)*\)r\=i\=\>" display
|
||||||
syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<0[oO]\=\o\+\%(_\o\+\)*r\=i\=\>" display
|
syn match rubyInteger "\%(\%(\w\|[^\x00-\x7F]\|[]})\"']\s*\)\@<!-\)\=\<0[oO]\=\o\+\%(_\o\+\)*r\=i\=\>" display
|
||||||
syn match rubyInteger "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<0[bB][01]\+\%(_[01]\+\)*r\=i\=\>" display
|
syn match rubyInteger "\%(\%(\w\|[^\x00-\x7F]\|[]})\"']\s*\)\@<!-\)\=\<0[bB][01]\+\%(_[01]\+\)*r\=i\=\>" display
|
||||||
syn match rubyFloat "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<\%(0\|[1-9]\d*\%(_\d\+\)*\)\.\d\+\%(_\d\+\)*r\=i\=\>" display
|
syn match rubyFloat "\%(\%(\w\|[^\x00-\x7F]\|[]})\"']\s*\)\@<!-\)\=\<\%(0\|[1-9]\d*\%(_\d\+\)*\)\.\d\+\%(_\d\+\)*r\=i\=\>" display
|
||||||
syn match rubyFloat "\%(\%(\w\|[]})\"']\s*\)\@<!-\)\=\<\%(0\|[1-9]\d*\%(_\d\+\)*\)\%(\.\d\+\%(_\d\+\)*\)\=\%([eE][-+]\=\d\+\%(_\d\+\)*\)i\=\>" display
|
syn match rubyFloat "\%(\%(\w\|[^\x00-\x7F]\|[]})\"']\s*\)\@<!-\)\=\<\%(0\|[1-9]\d*\%(_\d\+\)*\)\%(\.\d\+\%(_\d\+\)*\)\=\%([eE][-+]\=\d\+\%(_\d\+\)*\)i\=\>" display
|
||||||
|
|
||||||
" Identifiers {{{1
|
" Identifiers {{{1
|
||||||
syn match rubyLocalVariableOrMethod "\<[_[:lower:]][_[:alnum:]]*[?!]\=" contains=NONE display transparent
|
syn match rubyClassName "\%(\%(^\|[^.]\)\.\s*\)\@<!\<[[:upper:]]\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!" contained
|
||||||
syn match rubyBlockArgument "&[_[:lower:]][_[:alnum:]]" contains=NONE display transparent
|
syn match rubyModuleName "\%(\%(^\|[^.]\)\.\s*\)\@<!\<[[:upper:]]\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!" contained
|
||||||
|
syn match rubyConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<[[:upper:]]\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!"
|
||||||
syn match rubyClassName "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\u\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!" contained
|
|
||||||
syn match rubyModuleName "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\u\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!" contained
|
|
||||||
syn match rubyConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\u\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@!"
|
|
||||||
syn match rubyClassVariable "@@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display
|
syn match rubyClassVariable "@@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display
|
||||||
syn match rubyInstanceVariable "@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display
|
syn match rubyInstanceVariable "@\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" display
|
||||||
syn match rubyGlobalVariable "$\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\|-.\)"
|
syn match rubyGlobalVariable "$\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\|-.\)"
|
||||||
@@ -181,8 +196,8 @@ SynFold ':' syn region rubySymbol matchgroup=rubySymbolDelimiter start="[]})\"':
|
|||||||
|
|
||||||
syn match rubyCapitalizedMethod "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\u\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@="
|
syn match rubyCapitalizedMethod "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\u\%(\w\|[^\x00-\x7F]\)*\>\%(\s*(\)\@="
|
||||||
|
|
||||||
syn match rubyBlockParameter "\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*" contained
|
syn region rubyParentheses start="(" end=")" contains=ALLBUT,@rubyNotTop containedin=rubyBlockParameterList
|
||||||
syn region rubyBlockParameterList start="\%(\%(\<do\>\|{\)\_s*\)\@32<=|" end="|" oneline display contains=rubyBlockParameter
|
syn region rubyBlockParameterList start="\%(\%(\<do\>\|{\)\_s*\)\@32<=|" end="|" contains=ALLBUT,@rubyNotTop,@rubyProperOperator
|
||||||
|
|
||||||
if exists('ruby_global_variable_error')
|
if exists('ruby_global_variable_error')
|
||||||
syn match rubyGlobalVariableError "$[^A-Za-z_]" display
|
syn match rubyGlobalVariableError "$[^A-Za-z_]" display
|
||||||
@@ -195,7 +210,7 @@ syn match rubyPredefinedVariable "$_\>" display
|
|||||||
syn match rubyPredefinedVariable "$-[0FIWadilpvw]\>" display
|
syn match rubyPredefinedVariable "$-[0FIWadilpvw]\>" display
|
||||||
syn match rubyPredefinedVariable "$\%(stderr\|stdin\|stdout\)\>" display
|
syn match rubyPredefinedVariable "$\%(stderr\|stdin\|stdout\)\>" display
|
||||||
syn match rubyPredefinedVariable "$\%(DEBUG\|FILENAME\|LOADED_FEATURES\|LOAD_PATH\|PROGRAM_NAME\|SAFE\|VERBOSE\)\>" display
|
syn match rubyPredefinedVariable "$\%(DEBUG\|FILENAME\|LOADED_FEATURES\|LOAD_PATH\|PROGRAM_NAME\|SAFE\|VERBOSE\)\>" display
|
||||||
syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\%(ARGF\|ARGV\|ENV\|DATA\|FALSE\|NIL\|STDERR\|STDIN\|STDOUT\|TOPLEVEL_BINDING\|TRUE\)\>\%(\s*(\)\@!"
|
syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\%(ARGF\|ARGV\|ENV\|DATA\|STDERR\|STDIN\|STDOUT\|TOPLEVEL_BINDING\)\>\%(\s*(\)\@!"
|
||||||
syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\%(RUBY_\%(VERSION\|RELEASE_DATE\|PLATFORM\|PATCHLEVEL\|REVISION\|DESCRIPTION\|COPYRIGHT\|ENGINE\)\)\>\%(\s*(\)\@!"
|
syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\%(RUBY_\%(VERSION\|RELEASE_DATE\|PLATFORM\|PATCHLEVEL\|REVISION\|DESCRIPTION\|COPYRIGHT\|ENGINE\)\)\>\%(\s*(\)\@!"
|
||||||
|
|
||||||
" Deprecated/removed in 1.9
|
" Deprecated/removed in 1.9
|
||||||
@@ -203,12 +218,14 @@ syn match rubyPredefinedVariable "$="
|
|||||||
syn match rubyPredefinedVariable "$-K\>" display
|
syn match rubyPredefinedVariable "$-K\>" display
|
||||||
syn match rubyPredefinedVariable "$\%(deferr\|defout\)\>" display
|
syn match rubyPredefinedVariable "$\%(deferr\|defout\)\>" display
|
||||||
syn match rubyPredefinedVariable "$KCODE\>" display
|
syn match rubyPredefinedVariable "$KCODE\>" display
|
||||||
|
" Deprecated/removed in 2.4
|
||||||
|
syn match rubyPredefinedConstant "\%(\%(^\|[^.]\)\.\s*\)\@<!\<\%(FALSE\|NIL\|TRUE\)\>\%(\s*(\)\@!"
|
||||||
|
|
||||||
syn cluster rubyGlobalVariable contains=rubyGlobalVariable,rubyPredefinedVariable,rubyGlobalVariableError
|
syn cluster rubyGlobalVariable contains=rubyGlobalVariable,rubyPredefinedVariable,rubyGlobalVariableError
|
||||||
|
|
||||||
" Normal Regular Expressions {{{1
|
" Normal Regular Expressions {{{1
|
||||||
SynFold '/' syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\%(^\|\<\%(and\|or\|while\|until\|unless\|if\|elsif\|when\|not\|then\|else\)\|[;\~=!|&(,{[<>?:*+-]\)\s*\)\@<=/" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial nextgroup=@rubyModifier skipwhite
|
SynFold '/' syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\%(^\|\<\%(and\|or\|while\|until\|unless\|if\|elsif\|when\|not\|then\|else\)\|[;\~=!|&(,{[<>?:*+-]\)\s*\)\@<=/" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial nextgroup=@rubyModifier skipwhite
|
||||||
SynFold '/' syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\h\k*\s\+\)\@<=/\%([ \t=]\|$\)\@!" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial nextgroup=@rubyModifier skipwhite
|
SynFold '/' syn region rubyRegexp matchgroup=rubyRegexpDelimiter start="\%(\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\s\+\)\@<=/\%(=\|\_s\)\@!" end="/[iomxneus]*" skip="\\\\\|\\/" contains=@rubyRegexpSpecial nextgroup=@rubyModifier skipwhite
|
||||||
|
|
||||||
" Generalized Regular Expressions {{{1
|
" Generalized Regular Expressions {{{1
|
||||||
SynFold '%' syn region rubyRegexp matchgroup=rubyPercentRegexpDelimiter start="%r\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial nextgroup=@rubyModifier skipwhite
|
SynFold '%' syn region rubyRegexp matchgroup=rubyPercentRegexpDelimiter start="%r\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial nextgroup=@rubyModifier skipwhite
|
||||||
@@ -219,8 +236,8 @@ SynFold '%' syn region rubyRegexp matchgroup=rubyPercentRegexpDelimiter start="%
|
|||||||
SynFold '%' syn region rubyRegexp matchgroup=rubyPercentRegexpDelimiter start="%r\z(\s\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial
|
SynFold '%' syn region rubyRegexp matchgroup=rubyPercentRegexpDelimiter start="%r\z(\s\)" end="\z1[iomxneus]*" skip="\\\\\|\\\z1" contains=@rubyRegexpSpecial
|
||||||
|
|
||||||
" Characters {{{1
|
" Characters {{{1
|
||||||
syn match rubyCharacter "\%(\w\|[]})\"'/]\)\@1<!\%(?\%(\\M-\\C-\|\\C-\\M-\|\\M-\\c\|\\c\\M-\|\\c\|\\C-\|\\M-\)\=\%(\\\o\{1,3}\|\\x\x\{1,2}\|\\\=\S\)\)"
|
syn match rubyCharacter "\%(\w\|[^\x00-\x7F]\|[]})\"'/]\)\@1<!\%(?\%(\\M-\\C-\|\\C-\\M-\|\\M-\\c\|\\c\\M-\|\\c\|\\C-\|\\M-\)\=\%(\\\o\{1,3}\|\\x\x\{1,2}\|\\[[:space:]]\|\\\=[^[:space:]]\)\)"
|
||||||
syn match rubyCharacter "\%(\w\|[]})\"'/]\)\@1<!?\\u\%(\x\{4}\|{\x\{1,6}}\)"
|
syn match rubyCharacter "\%(\w\|[^\x00-\x7F]\|[]})\"'/]\)\@1<!?\\u\%(\x\{4}\|{\x\{1,6}}\)"
|
||||||
|
|
||||||
" Normal Strings {{{1
|
" Normal Strings {{{1
|
||||||
let s:spell_cluster = exists('ruby_spellcheck_strings') ? ',@Spell' : ''
|
let s:spell_cluster = exists('ruby_spellcheck_strings') ? ',@Spell' : ''
|
||||||
@@ -259,39 +276,38 @@ endfor
|
|||||||
unlet s:delimiter s:group s:names
|
unlet s:delimiter s:group s:names
|
||||||
" }}}2
|
" }}}2
|
||||||
|
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubyCurlyBracesEscape,rubyNestedCurlyBraces
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubyCurlyBraceEscape,rubyNestedCurlyBraces
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubyAngleBracketsEscape,rubyNestedAngleBrackets
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubyAngleBracketEscape,rubyNestedAngleBrackets
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySquareBracketsEscape,rubyNestedSquareBrackets
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySquareBracketEscape,rubyNestedSquareBrackets
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubyParenthesesEscape,rubyNestedParentheses
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubyParenthesisEscape,rubyNestedParentheses
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=rubyBackslashEscape,rubySpaceEscape
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%q\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=rubyBackslashEscape,rubySpaceEscape
|
||||||
|
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubySpaceEscape,rubyCurlyBracesEscape,rubyNestedCurlyBraces
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubySpaceEscape,rubyCurlyBraceEscape,rubyNestedCurlyBraces
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubySpaceEscape,rubyAngleBracketsEscape,rubyNestedAngleBrackets
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubySpaceEscape,rubyAngleBracketEscape,rubyNestedAngleBrackets
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySpaceEscape,rubySquareBracketsEscape,rubyNestedSquareBrackets
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySpaceEscape,rubySquareBracketEscape,rubyNestedSquareBrackets
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubySpaceEscape,rubyParenthesesEscape,rubyNestedParentheses
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%w(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubySpaceEscape,rubyParenthesisEscape,rubyNestedParentheses
|
||||||
|
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubyCurlyBracesEscape,rubyNestedCurlyBraces
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubyCurlyBraceEscape,rubyNestedCurlyBraces
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubyAngleBracketsEscape,rubyNestedAngleBrackets
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubyAngleBracketEscape,rubyNestedAngleBrackets
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySquareBracketsEscape,rubyNestedSquareBrackets
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySquareBracketEscape,rubyNestedSquareBrackets
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubyParenthesesEscape,rubyNestedParentheses
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%s(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubyParenthesisEscape,rubyNestedParentheses
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentSymbolDelimiter start="%s\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=rubyBackslashEscape,rubySpaceEscape
|
SynFold '%' syn region rubyString matchgroup=rubyPercentSymbolDelimiter start="%s\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=rubyBackslashEscape,rubySpaceEscape
|
||||||
|
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubySpaceEscape,rubyCurlyBracesEscape,rubyNestedCurlyBraces
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i{" end="}" skip="\\\\\|\\}" contains=rubyBackslashEscape,rubySpaceEscape,rubyCurlyBraceEscape,rubyNestedCurlyBraces
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubySpaceEscape,rubyAngleBracketsEscape,rubyNestedAngleBrackets
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i<" end=">" skip="\\\\\|\\>" contains=rubyBackslashEscape,rubySpaceEscape,rubyAngleBracketEscape,rubyNestedAngleBrackets
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySpaceEscape,rubySquareBracketsEscape,rubyNestedSquareBrackets
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i\[" end="\]" skip="\\\\\|\\\]" contains=rubyBackslashEscape,rubySpaceEscape,rubySquareBracketEscape,rubyNestedSquareBrackets
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubySpaceEscape,rubyParenthesesEscape,rubyNestedParentheses
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%i(" end=")" skip="\\\\\|\\)" contains=rubyBackslashEscape,rubySpaceEscape,rubyParenthesisEscape,rubyNestedParentheses
|
||||||
|
|
||||||
" Generalized Double Quoted Strings, Symbols, Array of Strings, Array of Symbols and Shell Command Output {{{1
|
" Generalized Double Quoted Strings, Array of Strings, Array of Symbols and Shell Command Output {{{1
|
||||||
" Note: %= is not matched here as the beginning of a double quoted string
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="\%(\%(\w\|[^\x00-\x7F]\|]\)\s*\)\@<!%=" end="=" skip="\\\\\|\\=" contains=@rubyStringSpecial nextgroup=@rubyModifier skipwhite
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%\z([~`!@#$%^&*_\-+|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial nextgroup=@rubyModifier skipwhite
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%\z([~`!@#$%^&*_\-+|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial nextgroup=@rubyModifier skipwhite
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial nextgroup=@rubyModifier skipwhite
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\={" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\={" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\=<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\=<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\=\[" end="\]" skip="\\\\\|\\\]" contains=@rubyStringSpecial,rubyNestedSquareBrackets
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\=\[" end="\]" skip="\\\\\|\\\]" contains=@rubyStringSpecial,rubyNestedSquareBrackets
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\=(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[QWx]\=(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses
|
||||||
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[Qx]\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial
|
SynFold '%' syn region rubyString matchgroup=rubyPercentStringDelimiter start="%[Qx]\z(\s\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial
|
||||||
|
|
||||||
" Array of interpolated Symbols
|
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial nextgroup=@rubyModifier skipwhite
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I\z([~`!@#$%^&*_\-+=|\:;"',.?/]\)" end="\z1" skip="\\\\\|\\\z1" contains=@rubyStringSpecial nextgroup=@rubyModifier skipwhite
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I{" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I{" end="}" skip="\\\\\|\\}" contains=@rubyStringSpecial,rubyNestedCurlyBraces
|
||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I<" end=">" skip="\\\\\|\\>" contains=@rubyStringSpecial,rubyNestedAngleBrackets
|
||||||
@@ -299,15 +315,16 @@ SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%
|
|||||||
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses
|
SynFold '%' syn region rubySymbol matchgroup=rubyPercentSymbolDelimiter start="%I(" end=")" skip="\\\\\|\\)" contains=@rubyStringSpecial,rubyNestedParentheses
|
||||||
|
|
||||||
" Here Documents {{{1
|
" Here Documents {{{1
|
||||||
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<[-~]\=\zs\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<[-~]\=\zs\%(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
||||||
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<[-~]\=\zs"\%([^"]*\)"+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
|
||||||
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<[-~]\=\zs'\%([^']*\)'+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
|
||||||
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<[-~]\=\zs`\%([^`]*\)`+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
|
||||||
|
|
||||||
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<\z(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<[-~]\=\zs"\%([^"]*\)"+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
||||||
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<"\z([^"]*\)"\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<[-~]\=\zs'\%([^']*\)'+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
||||||
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<'\z([^']*\)'\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart keepend
|
syn region rubyHeredocStart matchgroup=rubyHeredocDelimiter start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<[-~]\=\zs`\%([^`]*\)`+ end=+$+ oneline contains=ALLBUT,@rubyNotTop
|
||||||
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"']\)\s\|\w\)\@<!<<`\z([^`]*\)`\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
|
||||||
|
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<\z(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
||||||
|
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<"\z([^"]*\)"\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
||||||
|
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<'\z([^']*\)'\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart keepend
|
||||||
|
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})"'`]\)\s\|\w\)\@<!<<`\z([^`]*\)`\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+2 matchgroup=rubyHeredocDelimiter end=+^\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
||||||
|
|
||||||
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})]\)\s\|\w\)\@<!<<[-~]\z(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+3 matchgroup=rubyHeredocDelimiter end=+^\s*\zs\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})]\)\s\|\w\)\@<!<<[-~]\z(\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+3 matchgroup=rubyHeredocDelimiter end=+^\s*\zs\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
||||||
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})]\)\s\|\w\)\@<!<<[-~]"\z([^"]*\)"\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+3 matchgroup=rubyHeredocDelimiter end=+^\s*\zs\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([]})]\)\s\|\w\)\@<!<<[-~]"\z([^"]*\)"\ze\%(.*<<[-~]\=['`"]\=\h\)\@!+hs=s+3 matchgroup=rubyHeredocDelimiter end=+^\s*\zs\z1$+ contains=rubyHeredocStart,@rubyStringSpecial keepend
|
||||||
@@ -318,38 +335,37 @@ SynFold '<<' syn region rubyString start=+\%(\%(class\|::\|\.\@1<!\.\)\_s*\|\%([
|
|||||||
syn match rubyAliasDeclaration "[^[:space:];#.()]\+" contained contains=rubySymbol,@rubyGlobalVariable nextgroup=rubyAliasDeclaration2 skipwhite
|
syn match rubyAliasDeclaration "[^[:space:];#.()]\+" contained contains=rubySymbol,@rubyGlobalVariable nextgroup=rubyAliasDeclaration2 skipwhite
|
||||||
syn match rubyAliasDeclaration2 "[^[:space:];#.()]\+" contained contains=rubySymbol,@rubyGlobalVariable
|
syn match rubyAliasDeclaration2 "[^[:space:];#.()]\+" contained contains=rubySymbol,@rubyGlobalVariable
|
||||||
syn match rubyMethodDeclaration "[^[:space:];#(]\+" contained contains=rubyConstant,rubyBoolean,rubyPseudoVariable,rubyInstanceVariable,rubyClassVariable,rubyGlobalVariable
|
syn match rubyMethodDeclaration "[^[:space:];#(]\+" contained contains=rubyConstant,rubyBoolean,rubyPseudoVariable,rubyInstanceVariable,rubyClassVariable,rubyGlobalVariable
|
||||||
syn match rubyClassDeclaration "[^[:space:];#<]\+" contained contains=rubyClassName,rubyOperator
|
syn match rubyClassDeclaration "[^[:space:];#<]\+" contained contains=rubyClassName,rubyScopeOperator nextgroup=rubySuperClassOperator skipwhite skipnl
|
||||||
syn match rubyModuleDeclaration "[^[:space:];#<]\+" contained contains=rubyModuleName,rubyOperator
|
syn match rubyModuleDeclaration "[^[:space:];#<]\+" contained contains=rubyModuleName,rubyScopeOperator
|
||||||
|
|
||||||
syn match rubyMethodName "\<[_[:alpha:]][_[:alnum:]]*[?!=]\=[[:alnum:]_.:?!=]\@!" contained containedin=rubyMethodDeclaration
|
syn match rubyMethodName "\<\%([_[:alpha:]]\|[^\x00-\x7F]\)\%([_[:alnum:]]\|[^\x00-\x7F]\)*[?!=]\=\%([[:alnum:]_.:?!=]\|[^\x00-\x7F]\)\@!" contained containedin=rubyMethodDeclaration
|
||||||
syn match rubyMethodName "\%(\s\|^\)\@1<=[_[:alpha:]][_[:alnum:]]*[?!=]\=\%(\s\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2
|
syn match rubyMethodName "\%(\s\|^\)\@1<=\%([_[:alpha:]]\|[^\x00-\x7F]\)\%([_[:alnum:]]\|[^\x00-\x7F]\)*[?!=]\=\%(\s\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2
|
||||||
syn match rubyMethodName "\%([[:space:].]\|^\)\@1<=\%(\[\]=\=\|\*\*\|[-+!~]@\=\|[*/%|&^~]\|<<\|>>\|[<>]=\=\|<=>\|===\|[=!]=\|[=!]\~\|!\|`\)\%([[:space:];#(]\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration
|
syn match rubyMethodName "\%([[:space:].]\|^\)\@1<=\%(\[\]=\=\|\*\*\|[-+!~]@\=\|[*/%|&^~]\|<<\|>>\|[<>]=\=\|<=>\|===\|[=!]=\|[=!]\~\|!\|`\)\%([[:space:];#(]\|$\)\@=" contained containedin=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration
|
||||||
|
|
||||||
syn cluster rubyDeclaration contains=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration,rubyModuleDeclaration,rubyClassDeclaration,rubyMethodName,rubyBlockParameter
|
syn cluster rubyDeclaration contains=rubyAliasDeclaration,rubyAliasDeclaration2,rubyMethodDeclaration,rubyModuleDeclaration,rubyClassDeclaration,rubyMethodName
|
||||||
|
|
||||||
" Keywords {{{1
|
" Keywords {{{1
|
||||||
" Note: the following keywords have already been defined:
|
" TODO: reorganise
|
||||||
" begin case class def do end for if module unless until while
|
syn match rubyControl "\%#=1\<\%(break\|in\|next\|redo\|retry\|return\)\>"
|
||||||
syn match rubyControl "\<\%(and\|break\|in\|next\|not\|or\|redo\|retry\|return\)\>[?!]\@!"
|
syn match rubyKeyword "\%#=1\<\%(super\|yield\)\>"
|
||||||
syn match rubyOperator "\<defined?" display
|
syn match rubyBoolean "\%#=1\<\%(true\|false\)\>[?!]\@!"
|
||||||
syn match rubyKeyword "\<\%(super\|yield\)\>[?!]\@!"
|
syn match rubyPseudoVariable "\%#=1\<\(self\|nil\)\>[?!]\@!"
|
||||||
syn match rubyBoolean "\<\%(true\|false\)\>[?!]\@!"
|
syn match rubyPseudoVariable "\%#=1\<__\%(ENCODING\|dir\|FILE\|LINE\|callee\|method\)__\>"
|
||||||
syn match rubyPseudoVariable "\<\%(nil\|self\|__ENCODING__\|__dir__\|__FILE__\|__LINE__\|__callee__\|__method__\)\>[?!]\@!" " TODO: reorganise
|
syn match rubyBeginEnd "\%#=1\<\%(BEGIN\|END\)\>"
|
||||||
syn match rubyBeginEnd "\<\%(BEGIN\|END\)\>[?!]\@!"
|
|
||||||
|
|
||||||
" Expensive Mode {{{1
|
" Expensive Mode {{{1
|
||||||
" Match 'end' with the appropriate opening keyword for syntax based folding
|
" Match 'end' with the appropriate opening keyword for syntax based folding
|
||||||
" and special highlighting of module/class/method definitions
|
" and special highlighting of module/class/method definitions
|
||||||
if !exists("b:ruby_no_expensive") && !exists("ruby_no_expensive")
|
if !exists("b:ruby_no_expensive") && !exists("ruby_no_expensive")
|
||||||
syn match rubyDefine "\<alias\>" nextgroup=rubyAliasDeclaration skipwhite skipnl
|
syn match rubyDefine "\<alias\>" nextgroup=rubyAliasDeclaration skipwhite skipnl
|
||||||
syn match rubyDefine "\<def\>" nextgroup=rubyMethodDeclaration skipwhite skipnl
|
syn match rubyDefine "\<def\>" nextgroup=rubyMethodDeclaration skipwhite skipnl
|
||||||
syn match rubyDefine "\<undef\>" nextgroup=rubyMethodName skipwhite skipnl
|
syn match rubyDefine "\<undef\>" nextgroup=rubyMethodName skipwhite skipnl
|
||||||
syn match rubyClass "\<class\>" nextgroup=rubyClassDeclaration skipwhite skipnl
|
syn match rubyClass "\<class\>" nextgroup=rubyClassDeclaration,rubyEigenClassOperator skipwhite skipnl
|
||||||
syn match rubyModule "\<module\>" nextgroup=rubyModuleDeclaration skipwhite skipnl
|
syn match rubyModule "\<module\>" nextgroup=rubyModuleDeclaration skipwhite skipnl
|
||||||
|
|
||||||
SynFold 'def' syn region rubyMethodBlock start="\<def\>" matchgroup=rubyDefine end="\%(\<def\_s\+\)\@<!\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'def' syn region rubyMethodBlock start="\<def\>" matchgroup=rubyDefine skip="\<end:\|\%(\<def\_s\+\)\@<=end\>" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
SynFold 'class' syn region rubyClassBlock start="\<class\>" matchgroup=rubyClass end="\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'class' syn region rubyClassBlock start="\<class\>" matchgroup=rubyClass skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
SynFold 'module' syn region rubyModuleBlock start="\<module\>" matchgroup=rubyModule end="\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'module' syn region rubyModuleBlock start="\<module\>" matchgroup=rubyModule skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
" modifiers
|
" modifiers
|
||||||
syn match rubyLineContinuation "\\$" nextgroup=@rubyModifier skipwhite skipnl
|
syn match rubyLineContinuation "\\$" nextgroup=@rubyModifier skipwhite skipnl
|
||||||
@@ -359,29 +375,29 @@ if !exists("b:ruby_no_expensive") && !exists("ruby_no_expensive")
|
|||||||
|
|
||||||
syn cluster rubyModifier contains=rubyConditionalModifier,rubyRepeatModifier,rubyRescueModifier
|
syn cluster rubyModifier contains=rubyConditionalModifier,rubyRepeatModifier,rubyRescueModifier
|
||||||
|
|
||||||
SynFold 'do' syn region rubyDoBlock matchgroup=rubyControl start="\<do\>" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'do' syn region rubyDoBlock matchgroup=rubyControl start="\<do\>" skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
" curly bracket block or hash literal
|
" curly bracket block or hash literal
|
||||||
SynFold '{' syn region rubyCurlyBlock matchgroup=rubyCurlyBlockDelimiter start="{" end="}" contains=ALLBUT,@rubyNotTop
|
SynFold '{' syn region rubyCurlyBlock matchgroup=rubyCurlyBlockDelimiter start="{" end="}" contains=ALLBUT,@rubyNotTop
|
||||||
SynFold '[' syn region rubyArrayLiteral matchgroup=rubyArrayDelimiter start="\%(\w\|[\]})]\)\@<!\[" end="]" contains=ALLBUT,@rubyNotTop
|
SynFold '[' syn region rubyArrayLiteral matchgroup=rubyArrayDelimiter start="\%(\%(\w\|[^\x00-\x7F]\)[?!]\=\|[]})]\)\@2<!\[" end="]" contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
" statements without 'do'
|
" statements without 'do'
|
||||||
SynFold 'begin' syn region rubyBlockExpression matchgroup=rubyControl start="\<begin\>" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'begin' syn region rubyBlockExpression matchgroup=rubyControl start="\<begin\>" skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
SynFold 'case' syn region rubyCaseExpression matchgroup=rubyConditional start="\<case\>" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'case' syn region rubyCaseExpression matchgroup=rubyConditional start="\<case\>" skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
SynFold 'if' syn region rubyConditionalExpression matchgroup=rubyConditional start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+=-]\|\<then\s\|\%(\<\h\w*\)\@<![?!]\)\s*\)\@<=\%(if\|unless\)\>" end="\%(\%(\%(\.\@1<!\.\)\|::\)\s*\)\@<!\<end\>" contains=ALLBUT,@rubyNotTop
|
SynFold 'if' syn region rubyConditionalExpression matchgroup=rubyConditional start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+=-]\|\<then\s\|\%(\<\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\@<![?!]\)\s*\)\@<=\%(if\|unless\)\>" skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
syn match rubyConditional "\<\%(then\|else\|when\)\>[?!]\@!" contained containedin=rubyCaseExpression
|
syn match rubyConditional "\<\%(then\|else\|when\)\>" contained containedin=rubyCaseExpression
|
||||||
syn match rubyConditional "\<\%(then\|else\|elsif\)\>[?!]\@!" contained containedin=rubyConditionalExpression
|
syn match rubyConditional "\<\%(then\|else\|elsif\)\>" contained containedin=rubyConditionalExpression
|
||||||
|
|
||||||
syn match rubyExceptionHandler "\<\%(\%(\%(;\|^\)\s*\)\@<=rescue\|else\|ensure\)\>[?!]\@!" contained containedin=rubyBlockExpression,rubyDoBlock
|
syn match rubyExceptionHandler "\<\%(\%(\%(;\|^\)\s*\)\@<=rescue\|else\|ensure\)\>" contained containedin=rubyBlockExpression,rubyDoBlock
|
||||||
syn match rubyExceptionHandler1 "\<\%(\%(\%(;\|^\)\s*\)\@<=rescue\|else\|ensure\)\>[?!]\@!" contained containedin=rubyModuleBlock,rubyClassBlock,rubyMethodBlock
|
syn match rubyExceptionHandler2 "\<\%(\%(\%(;\|^\)\s*\)\@<=rescue\|else\|ensure\)\>" contained containedin=rubyModuleBlock,rubyClassBlock,rubyMethodBlock
|
||||||
syn cluster rubyExceptionHandler contains=rubyExceptionHandler,rubyExceptionHandler1
|
syn cluster rubyExceptionHandler contains=rubyExceptionHandler,rubyExceptionHandler2
|
||||||
|
|
||||||
" statements with optional 'do'
|
" statements with optional 'do'
|
||||||
syn region rubyOptionalDoLine matchgroup=rubyRepeat start="\<for\>[?!]\@!" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+=-]\|\%(\<\h\w*\)\@<![!?]\)\s*\)\@<=\<\%(until\|while\)\>" matchgroup=rubyOptionalDo end="\<do\>" end="\ze\%(;\|$\)" oneline contains=ALLBUT,@rubyNotTop
|
syn region rubyOptionalDoLine matchgroup=rubyRepeat start="\<for\>" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+=-]\|\%(\<\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\@<![!?]\)\s*\)\@<=\<\%(until\|while\)\>" matchgroup=rubyOptionalDo end="\<do\>" end="\ze\%(;\|$\)" oneline contains=ALLBUT,@rubyNotTop
|
||||||
|
|
||||||
SynFold 'for' syn region rubyRepeatExpression start="\<for\>[?!]\@!" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+=-]\|\%(\<\h\w*\)\@<![!?]\)\s*\)\@<=\<\%(until\|while\)\>" matchgroup=rubyRepeat end="\<end\>" contains=ALLBUT,@rubyNotTop nextgroup=rubyOptionalDoLine
|
SynFold 'for' syn region rubyRepeatExpression start="\<for\>" start="\%(\%(^\|\.\.\.\=\|[{:,;([<>~\*/%&^|+=-]\|\%(\<\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*\)\@<![!?]\)\s*\)\@<=\<\%(until\|while\)\>" matchgroup=rubyRepeat skip="\<end:" end="\<end\>" contains=ALLBUT,@rubyNotTop nextgroup=rubyOptionalDoLine
|
||||||
|
|
||||||
if !exists("ruby_minlines")
|
if !exists("ruby_minlines")
|
||||||
let ruby_minlines = 500
|
let ruby_minlines = 500
|
||||||
@@ -389,28 +405,29 @@ if !exists("b:ruby_no_expensive") && !exists("ruby_no_expensive")
|
|||||||
exe "syn sync minlines=" . ruby_minlines
|
exe "syn sync minlines=" . ruby_minlines
|
||||||
|
|
||||||
else
|
else
|
||||||
syn match rubyControl "\<def\>[?!]\@!" nextgroup=rubyMethodDeclaration skipwhite skipnl
|
syn match rubyControl "\<def\>" nextgroup=rubyMethodDeclaration skipwhite skipnl
|
||||||
syn match rubyControl "\<class\>[?!]\@!" nextgroup=rubyClassDeclaration skipwhite skipnl
|
syn match rubyControl "\<class\>" nextgroup=rubyClassDeclaration skipwhite skipnl
|
||||||
syn match rubyControl "\<module\>[?!]\@!" nextgroup=rubyModuleDeclaration skipwhite skipnl
|
syn match rubyControl "\<module\>" nextgroup=rubyModuleDeclaration skipwhite skipnl
|
||||||
syn match rubyControl "\<\%(case\|begin\|do\|for\|if\|unless\|while\|until\|else\|elsif\|rescue\|ensure\|then\|when\|end\)\>[?!]\@!"
|
syn match rubyControl "\<\%(case\|begin\|do\|for\|if\|unless\|while\|until\|else\|elsif\|rescue\|ensure\|then\|when\|end\)\>"
|
||||||
syn match rubyKeyword "\<\%(alias\|undef\)\>[?!]\@!"
|
syn match rubyKeyword "\<\%(alias\|undef\)\>"
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Special Methods {{{1
|
" Special Methods {{{1
|
||||||
if !exists("ruby_no_special_methods")
|
if !exists("ruby_no_special_methods")
|
||||||
syn keyword rubyAccess public protected private public_class_method private_class_method public_constant private_constant module_function
|
syn match rubyAccess "\<\%(public\|protected\|private\)\>" " use re=2
|
||||||
" attr is a common variable name
|
syn match rubyAccess "\%#=1\<\%(public\|private\)_class_method\>"
|
||||||
syn match rubyAttribute "\%(\%(^\|;\)\s*\)\@<=attr\>\(\s*[.=]\)\@!"
|
syn match rubyAccess "\%#=1\<\%(public\|private\)_constant\>"
|
||||||
syn keyword rubyAttribute attr_accessor attr_reader attr_writer
|
syn match rubyAccess "\%#=1\<module_function\>"
|
||||||
syn match rubyControl "\<\%(exit!\|\%(abort\|at_exit\|exit\|fork\|loop\|trap\)\>[?!]\@!\)"
|
syn match rubyAttribute "\%#=1\%(\%(^\|;\)\s*\)\@<=attr\>\(\s*[.=]\)\@!" " attr is a common variable name
|
||||||
syn keyword rubyEval eval class_eval instance_eval module_eval
|
syn match rubyAttribute "\%#=1\<attr_\%(accessor\|reader\|writer\)\>"
|
||||||
syn keyword rubyException raise fail catch throw
|
syn match rubyControl "\%#=1\<\%(abort\|at_exit\|exit\|fork\|loop\|trap\)\>"
|
||||||
syn keyword rubyInclude autoload gem load require require_relative
|
syn match rubyEval "\%#=1\<eval\>"
|
||||||
syn keyword rubyKeyword callcc caller lambda proc
|
syn match rubyEval "\%#=1\<\%(class\|instance\|module\)_eval\>"
|
||||||
" false positive with 'include?'
|
syn match rubyException "\%#=1\<\%(raise\|fail\|catch\|throw\)\>"
|
||||||
syn match rubyMacro "\<include\>[?!]\@!"
|
syn match rubyInclude "\%#=1\<\%(autoload\|gem\|load\|require\%(_relative\)\=\)\>"
|
||||||
syn keyword rubyMacro extend prepend refine using
|
syn match rubyKeyword "\%#=1\<\%(callcc\|caller\|lambda\|proc\)\>"
|
||||||
syn keyword rubyMacro alias_method define_method define_singleton_method remove_method undef_method
|
syn match rubyMacro "\%#=1\<\%(extend\|include\|prepend\|refine\|using\)\>"
|
||||||
|
syn match rubyMacro "\%#=1\<\%(alias\|define\|define_singleton\|remove\|undef\)_method\>"
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Comments and Documentation {{{1
|
" Comments and Documentation {{{1
|
||||||
@@ -431,20 +448,25 @@ else
|
|||||||
syn region rubyDocumentation start="^=begin\s*$" end="^=end\s*$" contains=rubySpaceError,rubyTodo,@Spell
|
syn region rubyDocumentation start="^=begin\s*$" end="^=end\s*$" contains=rubySpaceError,rubyTodo,@Spell
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" {{{1 Useless line continuations
|
" {{{1 Useless Line Continuations
|
||||||
syn match rubyUselessLineContinuation "\%([.:,;{([<>~\*%&^|+=-]\|\w\@1<![?!]\)\s*\zs\\$" nextgroup=rubyUselessLineContinuation skipwhite skipempty
|
syn match rubyUselessLineContinuation "\%([.:,;{([<>~\*%&^|+=-]\|%(\%(\w\|[^\x00-\x7F]\)\@1<![?!]\)\s*\zs\\$" nextgroup=rubyUselessLineContinuation skipwhite skipempty
|
||||||
syn match rubyUselessLineContinuation "\\$" nextgroup=rubyUselessLineContinuation skipwhite skipempty contained
|
syn match rubyUselessLineContinuation "\\$" nextgroup=rubyUselessLineContinuation skipwhite skipempty contained
|
||||||
|
|
||||||
" Keyword Nobbling {{{1
|
" Keyword Nobbling {{{1
|
||||||
" Note: this is a hack to prevent 'keywords' being highlighted as such when called as methods with an explicit receiver
|
" prevent methods with keyword names being highlighted as keywords when called
|
||||||
syn match rubyKeywordAsMethod "\%(\%(\.\@1<!\.\)\|::\)\_s*\%([_[:lower:]][_[:alnum:]]*\|\<\%(BEGIN\|END\)\>\)" transparent contains=NONE
|
syn match rubyKeywordAsMethod "\%(\%(\.\@1<!\.\)\|&\.\|::\)\_s*\%([_[:lower:]][_[:alnum:]]*\|\%(BEGIN\|END\)\>\)" transparent contains=rubyDotOperator,rubyScopeOperator
|
||||||
syn match rubyKeywordAsMethod "\(defined?\|exit!\)\@!\<[_[:lower:]][_[:alnum:]]*[?!]" transparent contains=NONE
|
|
||||||
|
|
||||||
" More Symbols {{{1
|
" Bang and Predicate Methods and Operators {{{1
|
||||||
syn match rubySymbol "\%([{(,]\_s*\)\@<=\l\w*[!?]\=::\@!"he=e-1
|
syn match rubyBangPredicateMethod "\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*[?!]"
|
||||||
syn match rubySymbol "[]})\"':]\@1<!\<\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*[!?]\=:[[:space:],]\@="he=e-1
|
|
||||||
syn match rubySymbol "\%([{(,]\_s*\)\@<=[[:space:],{]\l\w*[!?]\=::\@!"hs=s+1,he=e-1
|
if !exists("ruby_no_special_methods")
|
||||||
syn match rubySymbol "[[:space:],{(]\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*[!?]\=:[[:space:],]\@="hs=s+1,he=e-1
|
syn match rubyControl "\%#=1\<exit!" display
|
||||||
|
endif
|
||||||
|
syn match rubyDefinedOperator "\%#=1\<defined?" display
|
||||||
|
|
||||||
|
" 1.9-style Hash Keys and Keyword Parameters {{{1
|
||||||
|
syn match rubySymbol "\%([{(|,]\_s*\)\@<=\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*[?!]\=::\@!"he=e-1
|
||||||
|
syn match rubySymbol "[]})\"':]\@1<!\<\%(\h\|[^\x00-\x7F]\)\%(\w\|[^\x00-\x7F]\)*[!?]\=:[[:space:],;]\@="he=e-1
|
||||||
|
|
||||||
" __END__ Directive {{{1
|
" __END__ Directive {{{1
|
||||||
SynFold '__END__' syn region rubyData matchgroup=rubyDataDirective start="^__END__$" end="\%$"
|
SynFold '__END__' syn region rubyData matchgroup=rubyDataDirective start="^__END__$" end="\%$"
|
||||||
@@ -452,7 +474,7 @@ SynFold '__END__' syn region rubyData matchgroup=rubyDataDirective start="^__END
|
|||||||
" Default Highlighting {{{1
|
" Default Highlighting {{{1
|
||||||
hi def link rubyClass rubyDefine
|
hi def link rubyClass rubyDefine
|
||||||
hi def link rubyModule rubyDefine
|
hi def link rubyModule rubyDefine
|
||||||
hi def link rubyExceptionHandler1 rubyDefine
|
hi def link rubyExceptionHandler2 rubyDefine
|
||||||
hi def link rubyDefine Define
|
hi def link rubyDefine Define
|
||||||
hi def link rubyAccess rubyMacro
|
hi def link rubyAccess rubyMacro
|
||||||
hi def link rubyAttribute rubyMacro
|
hi def link rubyAttribute rubyMacro
|
||||||
@@ -491,21 +513,35 @@ hi def link rubySymbol Constant
|
|||||||
hi def link rubyKeyword Keyword
|
hi def link rubyKeyword Keyword
|
||||||
|
|
||||||
hi def link rubyOperator Operator
|
hi def link rubyOperator Operator
|
||||||
hi def link rubyDotOperator Operator
|
hi def link rubyDefinedOperator rubyOperator
|
||||||
hi def link rubyTernaryOperator Operator
|
hi def link rubyEnglishBooleanOperator rubyOperator
|
||||||
hi def link rubyArithmeticOperator Operator
|
if exists("ruby_operators")
|
||||||
hi def link rubyComparisonOperator Operator
|
hi def link rubyTernaryOperator rubyOperator
|
||||||
hi def link rubyBitwiseOperator Operator
|
hi def link rubyArithmeticOperator rubyOperator
|
||||||
hi def link rubyBooleanOperator Operator
|
hi def link rubyComparisonOperator rubyOperator
|
||||||
hi def link rubyRangeOperator Operator
|
hi def link rubyBitwiseOperator rubyOperator
|
||||||
hi def link rubyAssignmentOperator Operator
|
hi def link rubyBooleanOperator rubyOperator
|
||||||
hi def link rubyEqualityOperator Operator
|
hi def link rubyRangeOperator rubyOperator
|
||||||
hi def link rubyScopeOperator Operator
|
hi def link rubyAssignmentOperator rubyOperator
|
||||||
|
hi def link rubyEqualityOperator rubyOperator
|
||||||
|
endif
|
||||||
|
|
||||||
|
if exists("ruby_pseudo_operators")
|
||||||
|
hi def link rubyPseudoOperator Special
|
||||||
|
hi def link rubyDotOperator rubyPseudoOperator
|
||||||
|
hi def link rubyScopeOperator rubyPseudoOperator
|
||||||
|
hi def link rubySuperClassOperator rubyPseudoOperator
|
||||||
|
hi def link rubyEigenClassOperator rubyPseudoOperator
|
||||||
|
hi def link rubyLambdaOperator rubyPseudoOperator
|
||||||
|
hi def link rubyDoubleSplatOperator rubyPseudoOperator
|
||||||
|
hi def link rubySplatOperator rubyPseudoOperator
|
||||||
|
hi def link rubyProcOperator rubyPseudoOperator
|
||||||
|
endif
|
||||||
|
|
||||||
hi def link rubyBeginEnd Statement
|
hi def link rubyBeginEnd Statement
|
||||||
hi def link rubyEval Statement
|
hi def link rubyEval Statement
|
||||||
hi def link rubyPseudoVariable Constant
|
hi def link rubyPseudoVariable Constant
|
||||||
hi def link rubyCapitalizedMethod rubyLocalVariableOrMethod
|
hi def link rubyCapitalizedMethod NONE
|
||||||
|
|
||||||
hi def link rubyComment Comment
|
hi def link rubyComment Comment
|
||||||
hi def link rubyEncoding Constant
|
hi def link rubyEncoding Constant
|
||||||
@@ -518,10 +554,10 @@ hi def link rubyTodo Todo
|
|||||||
hi def link rubyBackslashEscape rubyStringEscape
|
hi def link rubyBackslashEscape rubyStringEscape
|
||||||
hi def link rubyQuoteEscape rubyStringEscape
|
hi def link rubyQuoteEscape rubyStringEscape
|
||||||
hi def link rubySpaceEscape rubyStringEscape
|
hi def link rubySpaceEscape rubyStringEscape
|
||||||
hi def link rubyParenthesesEscape rubyStringEscape
|
hi def link rubyParenthesisEscape rubyStringEscape
|
||||||
hi def link rubyCurlyBracesEscape rubyStringEscape
|
hi def link rubyCurlyBraceEscape rubyStringEscape
|
||||||
hi def link rubyAngleBracketsEscape rubyStringEscape
|
hi def link rubyAngleBracketEscape rubyStringEscape
|
||||||
hi def link rubySquareBracketsEscape rubyStringEscape
|
hi def link rubySquareBracketEscape rubyStringEscape
|
||||||
hi def link rubyStringEscape Special
|
hi def link rubyStringEscape Special
|
||||||
|
|
||||||
hi def link rubyInterpolationDelimiter Delimiter
|
hi def link rubyInterpolationDelimiter Delimiter
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ syn cluster scssSelectors contains=@comment,cssSelectorOp,cssTagName,cssPseudoCl
|
|||||||
syn match scssProperty "\([[:alnum:]-]\)\+\s*\(:\)\@=" contained contains=css.*Prop,cssVendor containedin=cssMediaBlock nextgroup=scssAttribute,scssAttributeWithNestedDefinition
|
syn match scssProperty "\([[:alnum:]-]\)\+\s*\(:\)\@=" contained contains=css.*Prop,cssVendor containedin=cssMediaBlock nextgroup=scssAttribute,scssAttributeWithNestedDefinition
|
||||||
syn match scssAttribute ":[^;]*\ze\(;\|}\)" contained contains=css.*Attr,cssValue.*,cssColor,cssFunction,cssString.*,cssURL,scssFunction,scssInterpolation,scssVariable
|
syn match scssAttribute ":[^;]*\ze\(;\|}\)" contained contains=css.*Attr,cssValue.*,cssColor,cssFunction,cssString.*,cssURL,scssFunction,scssInterpolation,scssVariable
|
||||||
|
|
||||||
syn match scssAttributeWithNestedDefinition ": [^#]*{\@=" nextgroup=scssNestedDefinition contained contains=css.*Attr,cssValue.*,scssVariable
|
syn match scssAttributeWithNestedDefinition ": [^#"]*{\@=" nextgroup=scssNestedDefinition contained contains=css.*Attr,cssValue.*,scssVariable
|
||||||
syn region scssNestedDefinition matchgroup=cssBraces start="{" end="}" contained contains=@comment,scssProperty,scssNestedProperty
|
syn region scssNestedDefinition matchgroup=cssBraces start="{" end="}" contained contains=@comment,scssProperty,scssNestedProperty
|
||||||
|
|
||||||
" CSS properties from https://developer.mozilla.org/en-US/docs/Web/CSS/Reference
|
" CSS properties from https://developer.mozilla.org/en-US/docs/Web/CSS/Reference
|
||||||
|
|||||||
149
syntax/svg.vim
Normal file
149
syntax/svg.vim
Normal file
@@ -0,0 +1,149 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'svg') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim syntax file
|
||||||
|
" Language: SVG
|
||||||
|
" Filenames: *.svg
|
||||||
|
" Maintainer: Michal Gorny <michal-gorny@wp.pl>
|
||||||
|
" Last_change: 2006-03-23
|
||||||
|
|
||||||
|
if !exists("main_syntax")
|
||||||
|
if exists("b:current_syntax")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
let main_syntax = 'svg'
|
||||||
|
endif
|
||||||
|
|
||||||
|
if main_syntax == 'svg'
|
||||||
|
runtime! syntax/xml.vim
|
||||||
|
syn cluster xmlTagHook add=svgElement
|
||||||
|
syn cluster xmlAttribHook add=svgAttr
|
||||||
|
syn match xmlDecl /\<\(<?\)\@<=xml\(-stylesheet\)\?\>/ containedin=xmlProcessing contained
|
||||||
|
syn keyword xmlDeclAttr version encoding standalone containedin=xmlProcessing contained
|
||||||
|
syn keyword xmlDeclAttr alternate charset media href title type containedin=xmlProcessing contained
|
||||||
|
else
|
||||||
|
syn cluster xhtmlTagHook add=svgElement
|
||||||
|
syn cluster xhtmlAttribHook add=svgAttr
|
||||||
|
endif
|
||||||
|
|
||||||
|
syn case match
|
||||||
|
|
||||||
|
" SVG elements
|
||||||
|
syn match svgElement contained /\<svg\>[^:]/me=e-1
|
||||||
|
syn keyword svgElement contained altGlyph altGlyphDef altGlyphItem animate
|
||||||
|
syn keyword svgElement contained animateColor animateMotion animateTransform
|
||||||
|
syn keyword svgElement contained circle clipPath cursor defs desc ellipse
|
||||||
|
syn keyword svgElement contained feBlend feColorMatrix feComponentTransfer
|
||||||
|
syn keyword svgElement contained feComposite feConvolveMatrix feDiffuseLighting
|
||||||
|
syn keyword svgElement contained feDisplacementMap feDistantLight feFlood
|
||||||
|
syn keyword svgElement contained feFuncA feFuncB feFuncG feFuncR feGaussianBlur
|
||||||
|
syn keyword svgElement contained feImage feMerge feMergeNode feMorphology
|
||||||
|
syn keyword svgElement contained feOffset fePointLight feSpecularLighting
|
||||||
|
syn keyword svgElement contained feSpotLight feTile feTurbulence filter
|
||||||
|
syn keyword svgElement contained foreignObject glyph glyphRef hkern image line
|
||||||
|
syn keyword svgElement contained linearGradient marker mask metadata mpath path
|
||||||
|
syn keyword svgElement contained pattern polygon polyline radialGradient rect
|
||||||
|
syn keyword svgElement contained script set stop style switch symbol text
|
||||||
|
syn keyword svgElement contained textPath title tref tspan use view vkern
|
||||||
|
syn match svgElement contained /\<\(font\|font-face\)\>[^-]/me=e-1
|
||||||
|
syn match svgElement contained /\<font-face-\(format\|name\|src\|uri\)\>/
|
||||||
|
syn match svgElement contained /\<\(color-profile\|definition-src\)\>/
|
||||||
|
syn match svgElement contained /\<missing-glyph\>/
|
||||||
|
syn match svgElement contained /\<\(a\|g\)\>[^:]/me=e-1
|
||||||
|
|
||||||
|
" SVG 1.0 attributes
|
||||||
|
syn keyword svgAttr contained accumulate additive alphabetic amplitude ascent attributeName attributeType azimuth baseFrequency bbox begin bias by
|
||||||
|
syn keyword svgAttr contained calcMode class clipPathUnits contentScriptType contentStyleType cursor cx cy d descent diffuseConstant direction display
|
||||||
|
syn keyword svgAttr contained divisor dur dx dy edgeMode elevation end exponent externalResourcesRequired filter filterRes filterUnits format from fx fy
|
||||||
|
syn keyword svgAttr contained g1 g2 glyphRef gradientTransform gradientUnits hanging height id ideographic in in2 intercept k k1 k2 k3 k4 kernelMatrix
|
||||||
|
syn keyword svgAttr contained kernelUnitLength kerning keyPoints keySplines keyTimes lang lengthAdjust limitingConeAngle local markerHeight markerUnits
|
||||||
|
syn keyword svgAttr contained markerWidth mask maskContentUnits maskUnits mathematical max media method min mode name numOctaves offset opacity operator
|
||||||
|
syn keyword svgAttr contained order orient orientation origin overflow path pathLength patternContentUnits patternTransform patternUnits points pointsAtX
|
||||||
|
syn keyword svgAttr contained pointsAtY pointsAtZ preserveAlpha preserveAspectRatio primitiveUnits r radius refX refY repeatCount repeatDur
|
||||||
|
syn keyword svgAttr contained requiredExtensions requiredFeatures restart result rotate rx ry scale seed slope spacing specularConstant specularExponent
|
||||||
|
syn keyword svgAttr contained spreadMethod startOffset stdDeviation stemh stemv stitchTiles string style surfaceScale systemLanguage tableValues target
|
||||||
|
syn keyword svgAttr contained targetX targetY textLength title to transform type u1 u2 values version viewBox viewTarget visibility width widths x x1 x2
|
||||||
|
syn keyword svgAttr contained xChannelSelector y y1 y2 yChannelSelector z zoomAndPan
|
||||||
|
syn match svgAttr contained /\<xmlns\>[^:]/me=e-1
|
||||||
|
syn match svgAttr contained /\<\(clip\|color\|fill\)\>[^-]/me=e-1
|
||||||
|
syn match svgAttr contained /\<\(stroke\|unicode\)\>[^-]/me=e-1
|
||||||
|
syn match svgAttr contained /\<\(color-interpolation\|font-size\)\>[^-]/me=e-1
|
||||||
|
syn match svgAttr contained /\<\(\accent-height\|alignment-baseline\|arabic-form\|baseline-shift\|cap-height\|clip-\(path\|rule\)\|dominant-baseline\)\>/
|
||||||
|
syn match svgAttr contained /\<\(color-\(interpolation-filters\|profile\|rendering\)\|enable-background\|fill-\(opacity\|rule\)\)\>/
|
||||||
|
syn match svgAttr contained /\<\(flood-\(color\|opacity\)\|font-\(family\|size-adjust\|stretch\|style\|variant\|weight\)\|image-rendering\)\>/
|
||||||
|
syn match svgAttr contained /\<\(glyph-\(name\|orientation-\(horizontal\|vertical\)\)\|horiz-\(adv-x\|origin-\(x\|y\)\)\)\>/
|
||||||
|
syn match svgAttr contained /\<\(letter-spacing\|lighting-color\|marker-\(end\|mid\|start\)\|overline-\(position\|thickness\)\|panose-1\)\>/
|
||||||
|
syn match svgAttr contained /\<\(pointer-events\|rendering-intent\|shape-rendering\|stop-\(color\|opacity\)\|strikethrough-\(position\|thickness\)\)\>/
|
||||||
|
syn match svgAttr contained /\<\(text-\(anchor\|decoration\|rendering\)\|stroke-\(dasharray\|dashoffset\|linecap\|linejoin\|miterlimit\|opacity\|width\)\)\>/
|
||||||
|
syn match svgAttr contained /\<\(underline-\(position\|thickness\)\|unicode-\(bidi\|range\)\|units-per-em\|writing-mode\|x-height\)\>/
|
||||||
|
syn match svgAttr contained /\(vert-\(adv-y\|origin-\(x\|y\)\)\|v-\(alphabetic\|hanging\|ideographic\|mathematical\)\|word-spacing\)\>/
|
||||||
|
syn match svgAttr contained /\<\(xlink:\)\@<=\(actuate\|arcrole\|href\)\>/
|
||||||
|
syn match svgAttr contained /\<\(xlink:\)\@<=\(role\|show\|title\|type\)\>/
|
||||||
|
syn match svgAttr contained /\<\(xml:\)\@<=\(base\|lang\|space\)\>/
|
||||||
|
syn match svgAttr contained /\<\(xmlns:\)\@<=xlink\>/
|
||||||
|
" Events attributes
|
||||||
|
if exists("svg_no_events_rendering")
|
||||||
|
syn match svgEventAttr contained /\<on\(abort\|activate\|begin\|click\|end\|error\|focus\(in\|out\)\|\(un\)\?load\|mouse\(down\|move\|out\|over\|up\)\|repeat\|resize\|scroll\|zoom\)\>/
|
||||||
|
if main_syntax == 'svg'
|
||||||
|
syn cluster xmlAttribHook add=svgEventAttr
|
||||||
|
else
|
||||||
|
syn cluster xhtmlAttribHook add=svgEventAttr
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Attribute new in SVG 1.1
|
||||||
|
syn keyword svgAttr contained baseProfile
|
||||||
|
|
||||||
|
" Embedded ECMAScript (JavaScript)
|
||||||
|
if main_syntax == 'svg'
|
||||||
|
syn include @svgJavaScript syntax/javascript.vim
|
||||||
|
unlet b:current_syntax
|
||||||
|
syn region javaScript start=+<script[^>]*[^/]>+ keepend end=+</script>+me=s-1 contains=@svgJavaScript,svgScriptTag
|
||||||
|
syn region svgScriptTag contained start=+<script+ end=+>+ contains=xmlTagName,xmlString,xmlAttrib
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Events attributes rendering
|
||||||
|
if !exists("svg_no_events_rendering")
|
||||||
|
syn region svgEvent contained start=+\<on\(abort\|activate\|begin\|click\|end\|error\|focus\(in\|out\)\|\(un\)\?load\|mouse\(down\|move\|out\|over\|up\)\|repeat\|resize\|scroll\|zoom\)\s*=\s*'+ keepend end=+'+ contains=svgEventSQ
|
||||||
|
syn region svgEvent contained start=+\<on\(abort\|activate\|begin\|click\|end\|error\|focus\(in\|out\)\|\(un\)\?load\|mouse\(down\|move\|out\|over\|up\)\|repeat\|resize\|scroll\|zoom\)\s*=\s*"+ keepend end=+"+ contains=svgEventDQ
|
||||||
|
if main_syntax == 'svg'
|
||||||
|
syn cluster xmlAttribHook add=svgEvent
|
||||||
|
else
|
||||||
|
syn cluster xhtmlAttribHook add=svgEvent
|
||||||
|
endif
|
||||||
|
syn region svgEventSQ contained start=+'+ms=s+1 end=+'+me=s-1 contains=@svgJavaScript,@xhtmlJavaScript
|
||||||
|
syn region svgEventDQ contained start=+"+ms=s+1 end=+"+me=s-1 contains=@svgJavaScript,@xhtmlJavaScript
|
||||||
|
hi def link svgEventSQ svgEvent
|
||||||
|
hi def link svgEventDQ svgEvent
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Rendering
|
||||||
|
if !exists("svg_no_rendering")
|
||||||
|
syn region svgTitle start="<title\>" end="</title>"me=e-8 contains=xmlTag,xmlEndTag,xmlEntity,xmlComment
|
||||||
|
syn region svgDesc start="<desc\>" end="</desc>"me=e-8 contains=xmlTag,xmlEndTag,xmlEntity,xmlComment
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Highlighting
|
||||||
|
hi link xmlAttrib Function
|
||||||
|
hi def link xmlDecl Statement
|
||||||
|
hi def link xmlDeclAttr Type
|
||||||
|
hi link xmlEntity Special
|
||||||
|
hi link xmlEntityPunct Special
|
||||||
|
hi def link svgElement Statement
|
||||||
|
hi def link svgAttr Type
|
||||||
|
hi def link javaScript Special
|
||||||
|
hi def link svgEvent javaScript
|
||||||
|
hi def link svgEventAttr Type
|
||||||
|
if !exists("svg_no_rendering")
|
||||||
|
hi def link svgTitle Title
|
||||||
|
hi def link svgDesc Title
|
||||||
|
endif
|
||||||
|
|
||||||
|
let b:current_syntax = "svg"
|
||||||
|
|
||||||
|
if main_syntax == 'svg'
|
||||||
|
unlet main_syntax
|
||||||
|
endif
|
||||||
|
|
||||||
|
" vim: ts=8
|
||||||
58
syntax/tablegen.vim
Normal file
58
syntax/tablegen.vim
Normal file
@@ -0,0 +1,58 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'llvm') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim syntax file
|
||||||
|
" Language: TableGen
|
||||||
|
" Maintainer: The LLVM team, http://llvm.org/
|
||||||
|
" Version: $Revision$
|
||||||
|
|
||||||
|
if version < 600
|
||||||
|
syntax clear
|
||||||
|
elseif exists("b:current_syntax")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" May be changed if you have a really slow machine
|
||||||
|
syntax sync minlines=100
|
||||||
|
|
||||||
|
syn case match
|
||||||
|
|
||||||
|
syn keyword tgKeyword def let in code dag field include defm foreach
|
||||||
|
syn keyword tgType class int string list bit bits multiclass
|
||||||
|
|
||||||
|
syn match tgNumber /\<\d\+\>/
|
||||||
|
syn match tgNumber /\<\d\+\.\d*\>/
|
||||||
|
syn match tgNumber /\<0b[01]\+\>/
|
||||||
|
syn match tgNumber /\<0x[0-9a-fA-F]\+\>/
|
||||||
|
syn region tgString start=/"/ skip=/\\"/ end=/"/ oneline
|
||||||
|
|
||||||
|
syn region tgCode start=/\[{/ end=/}\]/
|
||||||
|
|
||||||
|
syn keyword tgTodo contained TODO FIXME
|
||||||
|
syn match tgComment /\/\/.*$/ contains=tgTodo
|
||||||
|
" Handle correctly imbricated comment
|
||||||
|
syn region tgComment2 matchgroup=tgComment2 start=+/\*+ end=+\*/+ contains=tgTodo,tgComment2
|
||||||
|
|
||||||
|
if version >= 508 || !exists("did_c_syn_inits")
|
||||||
|
if version < 508
|
||||||
|
let did_c_syn_inits = 1
|
||||||
|
command -nargs=+ HiLink hi link <args>
|
||||||
|
else
|
||||||
|
command -nargs=+ HiLink hi def link <args>
|
||||||
|
endif
|
||||||
|
|
||||||
|
HiLink tgKeyword Statement
|
||||||
|
HiLink tgType Type
|
||||||
|
HiLink tgNumber Number
|
||||||
|
HiLink tgComment Comment
|
||||||
|
HiLink tgComment2 Comment
|
||||||
|
HiLink tgString String
|
||||||
|
" May find a better Hilight group...
|
||||||
|
HiLink tgCode Special
|
||||||
|
HiLink tgTodo Todo
|
||||||
|
|
||||||
|
delcommand HiLink
|
||||||
|
endif
|
||||||
|
|
||||||
|
let b:current_syntax = "tablegen"
|
||||||
@@ -21,14 +21,21 @@ syn keyword terraValueBool true false on off yes no
|
|||||||
""" data
|
""" data
|
||||||
syn keyword terraDataTypeBI
|
syn keyword terraDataTypeBI
|
||||||
\ alicloud_account
|
\ alicloud_account
|
||||||
|
\ alicloud_actiontrails
|
||||||
\ alicloud_api_gateway_apis
|
\ alicloud_api_gateway_apis
|
||||||
\ alicloud_api_gateway_apps
|
\ alicloud_api_gateway_apps
|
||||||
\ alicloud_api_gateway_groups
|
\ alicloud_api_gateway_groups
|
||||||
|
\ alicloud_cas_certificates
|
||||||
\ alicloud_cen_bandwidth_limits
|
\ alicloud_cen_bandwidth_limits
|
||||||
\ alicloud_cen_bandwidth_packages
|
\ alicloud_cen_bandwidth_packages
|
||||||
\ alicloud_cen_instances
|
\ alicloud_cen_instances
|
||||||
\ alicloud_cen_region_route_entries
|
\ alicloud_cen_region_route_entries
|
||||||
\ alicloud_cen_route_entries
|
\ alicloud_cen_route_entries
|
||||||
|
\ alicloud_common_bandwidth_packages
|
||||||
|
\ alicloud_cr_namespaces
|
||||||
|
\ alicloud_cr_repos
|
||||||
|
\ alicloud_cs_kubernetes_clusters
|
||||||
|
\ alicloud_cs_managed_kubernetes_clusters
|
||||||
\ alicloud_db_instances
|
\ alicloud_db_instances
|
||||||
\ alicloud_disks
|
\ alicloud_disks
|
||||||
\ alicloud_dns_domain_groups
|
\ alicloud_dns_domain_groups
|
||||||
@@ -36,11 +43,13 @@ syn keyword terraDataTypeBI
|
|||||||
\ alicloud_dns_domains
|
\ alicloud_dns_domains
|
||||||
\ alicloud_dns_groups
|
\ alicloud_dns_groups
|
||||||
\ alicloud_dns_records
|
\ alicloud_dns_records
|
||||||
|
\ alicloud_drds_instances
|
||||||
\ alicloud_eips
|
\ alicloud_eips
|
||||||
\ alicloud_elasticsearch_instances
|
\ alicloud_elasticsearch_instances
|
||||||
\ alicloud_fc_functions
|
\ alicloud_fc_functions
|
||||||
\ alicloud_fc_services
|
\ alicloud_fc_services
|
||||||
\ alicloud_fc_triggers
|
\ alicloud_fc_triggers
|
||||||
|
\ alicloud_forward_entries
|
||||||
\ alicloud_images
|
\ alicloud_images
|
||||||
\ alicloud_instance_types
|
\ alicloud_instance_types
|
||||||
\ alicloud_instances
|
\ alicloud_instances
|
||||||
@@ -51,6 +60,11 @@ syn keyword terraDataTypeBI
|
|||||||
\ alicloud_mns_topic_subscriptions
|
\ alicloud_mns_topic_subscriptions
|
||||||
\ alicloud_mns_topics
|
\ alicloud_mns_topics
|
||||||
\ alicloud_mongo_instances
|
\ alicloud_mongo_instances
|
||||||
|
\ alicloud_nas_access_groups
|
||||||
|
\ alicloud_nas_access_rules
|
||||||
|
\ alicloud_nas_file_systems
|
||||||
|
\ alicloud_nas_mount_targets
|
||||||
|
\ alicloud_nat_gateways
|
||||||
\ alicloud_network_interfaces
|
\ alicloud_network_interfaces
|
||||||
\ alicloud_oss_bucket_objects
|
\ alicloud_oss_bucket_objects
|
||||||
\ alicloud_oss_buckets
|
\ alicloud_oss_buckets
|
||||||
@@ -63,6 +77,8 @@ syn keyword terraDataTypeBI
|
|||||||
\ alicloud_ram_roles
|
\ alicloud_ram_roles
|
||||||
\ alicloud_ram_users
|
\ alicloud_ram_users
|
||||||
\ alicloud_regions
|
\ alicloud_regions
|
||||||
|
\ alicloud_route_entries
|
||||||
|
\ alicloud_route_tables
|
||||||
\ alicloud_router_interfaces
|
\ alicloud_router_interfaces
|
||||||
\ alicloud_security_group_rules
|
\ alicloud_security_group_rules
|
||||||
\ alicloud_security_groups
|
\ alicloud_security_groups
|
||||||
@@ -74,6 +90,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ alicloud_slb_server_certificates
|
\ alicloud_slb_server_certificates
|
||||||
\ alicloud_slb_server_groups
|
\ alicloud_slb_server_groups
|
||||||
\ alicloud_slbs
|
\ alicloud_slbs
|
||||||
|
\ alicloud_snat_entries
|
||||||
\ alicloud_vpcs
|
\ alicloud_vpcs
|
||||||
\ alicloud_vpn_connections
|
\ alicloud_vpn_connections
|
||||||
\ alicloud_vpn_customer_gateways
|
\ alicloud_vpn_customer_gateways
|
||||||
@@ -124,6 +141,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ aws_ec2_transit_gateway
|
\ aws_ec2_transit_gateway
|
||||||
\ aws_ec2_transit_gateway_route_table
|
\ aws_ec2_transit_gateway_route_table
|
||||||
\ aws_ec2_transit_gateway_vpc_attachment
|
\ aws_ec2_transit_gateway_vpc_attachment
|
||||||
|
\ aws_ec2_transit_gateway_vpn_attachment
|
||||||
\ aws_ecr_repository
|
\ aws_ecr_repository
|
||||||
\ aws_ecs_cluster
|
\ aws_ecs_cluster
|
||||||
\ aws_ecs_container_definition
|
\ aws_ecs_container_definition
|
||||||
@@ -200,6 +218,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ aws_storagegateway_local_disk
|
\ aws_storagegateway_local_disk
|
||||||
\ aws_subnet
|
\ aws_subnet
|
||||||
\ aws_subnet_ids
|
\ aws_subnet_ids
|
||||||
|
\ aws_transfer_server
|
||||||
\ aws_vpc
|
\ aws_vpc
|
||||||
\ aws_vpc_dhcp_options
|
\ aws_vpc_dhcp_options
|
||||||
\ aws_vpc_endpoint
|
\ aws_vpc_endpoint
|
||||||
@@ -210,6 +229,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ aws_workspaces_bundle
|
\ aws_workspaces_bundle
|
||||||
\ azuread_user
|
\ azuread_user
|
||||||
\ azurerm_api_management
|
\ azurerm_api_management
|
||||||
|
\ azurerm_api_management_api
|
||||||
\ azurerm_api_management_group
|
\ azurerm_api_management_group
|
||||||
\ azurerm_api_management_product
|
\ azurerm_api_management_product
|
||||||
\ azurerm_api_management_user
|
\ azurerm_api_management_user
|
||||||
@@ -392,6 +412,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ google_container_registry_repository
|
\ google_container_registry_repository
|
||||||
\ google_dns_managed_zone
|
\ google_dns_managed_zone
|
||||||
\ google_folder
|
\ google_folder
|
||||||
|
\ google_folder_organization_policy
|
||||||
\ google_iam_policy
|
\ google_iam_policy
|
||||||
\ google_iam_role
|
\ google_iam_role
|
||||||
\ google_kms_crypto_key
|
\ google_kms_crypto_key
|
||||||
@@ -400,13 +421,16 @@ syn keyword terraDataTypeBI
|
|||||||
\ google_netblock_ip_ranges
|
\ google_netblock_ip_ranges
|
||||||
\ google_organization
|
\ google_organization
|
||||||
\ google_project
|
\ google_project
|
||||||
|
\ google_project_organization_policy
|
||||||
\ google_project_services
|
\ google_project_services
|
||||||
|
\ google_projects
|
||||||
\ google_service_account
|
\ google_service_account
|
||||||
\ google_service_account_key
|
\ google_service_account_key
|
||||||
\ google_storage_bucket_object
|
\ google_storage_bucket_object
|
||||||
\ google_storage_object_signed_url
|
\ google_storage_object_signed_url
|
||||||
\ google_storage_project_service_account
|
\ google_storage_project_service_account
|
||||||
\ google_storage_transfer_project_service_account
|
\ google_storage_transfer_project_service_account
|
||||||
|
\ google_tpu_tensorflow_versions
|
||||||
\ grafana_data_source
|
\ grafana_data_source
|
||||||
\ hcloud_datacenter
|
\ hcloud_datacenter
|
||||||
\ hcloud_datacenters
|
\ hcloud_datacenters
|
||||||
@@ -421,6 +445,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ heroku_app
|
\ heroku_app
|
||||||
\ heroku_space
|
\ heroku_space
|
||||||
\ heroku_space_peering_info
|
\ heroku_space_peering_info
|
||||||
|
\ heroku_team
|
||||||
\ http
|
\ http
|
||||||
\ huaweicloud_antiddos_v1
|
\ huaweicloud_antiddos_v1
|
||||||
\ huaweicloud_cce_cluster_v3
|
\ huaweicloud_cce_cluster_v3
|
||||||
@@ -471,6 +496,24 @@ syn keyword terraDataTypeBI
|
|||||||
\ logentries_logset
|
\ logentries_logset
|
||||||
\ logicmonitor_collectors
|
\ logicmonitor_collectors
|
||||||
\ logicmonitor_device_group
|
\ logicmonitor_device_group
|
||||||
|
\ ncloud_access_control_group
|
||||||
|
\ ncloud_access_control_groups
|
||||||
|
\ ncloud_access_control_rule
|
||||||
|
\ ncloud_access_control_rules
|
||||||
|
\ ncloud_member_server_image
|
||||||
|
\ ncloud_member_server_images
|
||||||
|
\ ncloud_nas_volume
|
||||||
|
\ ncloud_nas_volumes
|
||||||
|
\ ncloud_port_forwarding_rule
|
||||||
|
\ ncloud_port_forwarding_rules
|
||||||
|
\ ncloud_public_ip
|
||||||
|
\ ncloud_regions
|
||||||
|
\ ncloud_root_password
|
||||||
|
\ ncloud_server_image
|
||||||
|
\ ncloud_server_images
|
||||||
|
\ ncloud_server_product
|
||||||
|
\ ncloud_server_products
|
||||||
|
\ ncloud_zones
|
||||||
\ newrelic_alert_channel
|
\ newrelic_alert_channel
|
||||||
\ newrelic_alert_policy
|
\ newrelic_alert_policy
|
||||||
\ newrelic_application
|
\ newrelic_application
|
||||||
@@ -502,6 +545,12 @@ syn keyword terraDataTypeBI
|
|||||||
\ nutanix_volume_groups
|
\ nutanix_volume_groups
|
||||||
\ oci_audit_configuration
|
\ oci_audit_configuration
|
||||||
\ oci_audit_events
|
\ oci_audit_events
|
||||||
|
\ oci_autoscaling_auto_scaling_configuration
|
||||||
|
\ oci_autoscaling_auto_scaling_configurations
|
||||||
|
\ oci_budget_alert_rule
|
||||||
|
\ oci_budget_alert_rules
|
||||||
|
\ oci_budget_budget
|
||||||
|
\ oci_budget_budgets
|
||||||
\ oci_containerengine_cluster_kube_config
|
\ oci_containerengine_cluster_kube_config
|
||||||
\ oci_containerengine_cluster_option
|
\ oci_containerengine_cluster_option
|
||||||
\ oci_containerengine_clusters
|
\ oci_containerengine_clusters
|
||||||
@@ -596,6 +645,8 @@ syn keyword terraDataTypeBI
|
|||||||
\ oci_database_autonomous_database_wallet
|
\ oci_database_autonomous_database_wallet
|
||||||
\ oci_database_autonomous_databases
|
\ oci_database_autonomous_databases
|
||||||
\ oci_database_backups
|
\ oci_database_backups
|
||||||
|
\ oci_database_data_guard_association
|
||||||
|
\ oci_database_data_guard_associations
|
||||||
\ oci_database_database
|
\ oci_database_database
|
||||||
\ oci_database_databases
|
\ oci_database_databases
|
||||||
\ oci_database_db_home
|
\ oci_database_db_home
|
||||||
@@ -609,6 +660,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ oci_database_db_system_shapes
|
\ oci_database_db_system_shapes
|
||||||
\ oci_database_db_systems
|
\ oci_database_db_systems
|
||||||
\ oci_database_db_versions
|
\ oci_database_db_versions
|
||||||
|
\ oci_database_exadata_iorm_config
|
||||||
\ oci_dns_records
|
\ oci_dns_records
|
||||||
\ oci_dns_steering_policies
|
\ oci_dns_steering_policies
|
||||||
\ oci_dns_steering_policy
|
\ oci_dns_steering_policy
|
||||||
@@ -633,6 +685,8 @@ syn keyword terraDataTypeBI
|
|||||||
\ oci_health_checks_vantage_points
|
\ oci_health_checks_vantage_points
|
||||||
\ oci_identity_api_keys
|
\ oci_identity_api_keys
|
||||||
\ oci_identity_auth_tokens
|
\ oci_identity_auth_tokens
|
||||||
|
\ oci_identity_authentication_policy
|
||||||
|
\ oci_identity_availability_domain
|
||||||
\ oci_identity_availability_domains
|
\ oci_identity_availability_domains
|
||||||
\ oci_identity_compartment
|
\ oci_identity_compartment
|
||||||
\ oci_identity_compartments
|
\ oci_identity_compartments
|
||||||
@@ -648,6 +702,8 @@ syn keyword terraDataTypeBI
|
|||||||
\ oci_identity_regions
|
\ oci_identity_regions
|
||||||
\ oci_identity_smtp_credentials
|
\ oci_identity_smtp_credentials
|
||||||
\ oci_identity_swift_passwords
|
\ oci_identity_swift_passwords
|
||||||
|
\ oci_identity_tag_default
|
||||||
|
\ oci_identity_tag_defaults
|
||||||
\ oci_identity_tag_namespaces
|
\ oci_identity_tag_namespaces
|
||||||
\ oci_identity_tags
|
\ oci_identity_tags
|
||||||
\ oci_identity_tenancy
|
\ oci_identity_tenancy
|
||||||
@@ -677,6 +733,12 @@ syn keyword terraDataTypeBI
|
|||||||
\ oci_load_balancer_rule_sets
|
\ oci_load_balancer_rule_sets
|
||||||
\ oci_load_balancer_shapes
|
\ oci_load_balancer_shapes
|
||||||
\ oci_load_balancers
|
\ oci_load_balancers
|
||||||
|
\ oci_monitoring_alarm
|
||||||
|
\ oci_monitoring_alarm_history_collection
|
||||||
|
\ oci_monitoring_alarm_statuses
|
||||||
|
\ oci_monitoring_alarms
|
||||||
|
\ oci_monitoring_metric_data
|
||||||
|
\ oci_monitoring_metrics
|
||||||
\ oci_objectstorage_bucket
|
\ oci_objectstorage_bucket
|
||||||
\ oci_objectstorage_bucket_summaries
|
\ oci_objectstorage_bucket_summaries
|
||||||
\ oci_objectstorage_namespace
|
\ oci_objectstorage_namespace
|
||||||
@@ -687,8 +749,17 @@ syn keyword terraDataTypeBI
|
|||||||
\ oci_objectstorage_objects
|
\ oci_objectstorage_objects
|
||||||
\ oci_objectstorage_preauthrequest
|
\ oci_objectstorage_preauthrequest
|
||||||
\ oci_objectstorage_preauthrequests
|
\ oci_objectstorage_preauthrequests
|
||||||
|
\ oci_ons_notification_topic
|
||||||
|
\ oci_ons_notification_topics
|
||||||
|
\ oci_ons_subscription
|
||||||
|
\ oci_ons_subscriptions
|
||||||
\ oci_streaming_stream
|
\ oci_streaming_stream
|
||||||
\ oci_streaming_streams
|
\ oci_streaming_streams
|
||||||
|
\ oci_waas_certificate
|
||||||
|
\ oci_waas_certificates
|
||||||
|
\ oci_waas_edge_subnets
|
||||||
|
\ oci_waas_waas_policies
|
||||||
|
\ oci_waas_waas_policy
|
||||||
\ oneandone_instance_size
|
\ oneandone_instance_size
|
||||||
\ opc_compute_image_list_entry
|
\ opc_compute_image_list_entry
|
||||||
\ opc_compute_ip_address_reservation
|
\ opc_compute_ip_address_reservation
|
||||||
@@ -723,6 +794,7 @@ syn keyword terraDataTypeBI
|
|||||||
\ openstack_networking_secgroup_v2
|
\ openstack_networking_secgroup_v2
|
||||||
\ openstack_networking_subnet_v2
|
\ openstack_networking_subnet_v2
|
||||||
\ openstack_networking_subnetpool_v2
|
\ openstack_networking_subnetpool_v2
|
||||||
|
\ openstack_networking_trunk_v2
|
||||||
\ openstack_sharedfilesystem_availability_zones_v2
|
\ openstack_sharedfilesystem_availability_zones_v2
|
||||||
\ openstack_sharedfilesystem_share_v2
|
\ openstack_sharedfilesystem_share_v2
|
||||||
\ openstack_sharedfilesystem_sharenetwork_v2
|
\ openstack_sharedfilesystem_sharenetwork_v2
|
||||||
@@ -872,8 +944,14 @@ syn keyword terraDataTypeBI
|
|||||||
\ triton_image
|
\ triton_image
|
||||||
\ triton_network
|
\ triton_network
|
||||||
\ triton_package
|
\ triton_package
|
||||||
|
\ ucloud_disks
|
||||||
\ ucloud_eips
|
\ ucloud_eips
|
||||||
\ ucloud_images
|
\ ucloud_images
|
||||||
|
\ ucloud_instances
|
||||||
|
\ ucloud_lb_attachments
|
||||||
|
\ ucloud_lb_listeners
|
||||||
|
\ ucloud_lb_rules
|
||||||
|
\ ucloud_lbs
|
||||||
\ ucloud_projects
|
\ ucloud_projects
|
||||||
\ ucloud_zones
|
\ ucloud_zones
|
||||||
\ vault_approle_auth_backend_role_id
|
\ vault_approle_auth_backend_role_id
|
||||||
@@ -915,22 +993,29 @@ syn keyword terraDataTypeBI
|
|||||||
syn keyword terraResourceTypeBI
|
syn keyword terraResourceTypeBI
|
||||||
\ acme_certificate
|
\ acme_certificate
|
||||||
\ acme_registration
|
\ acme_registration
|
||||||
|
\ alicloud_actiontrail
|
||||||
\ alicloud_api_gateway_api
|
\ alicloud_api_gateway_api
|
||||||
\ alicloud_api_gateway_app
|
\ alicloud_api_gateway_app
|
||||||
\ alicloud_api_gateway_app_attachment
|
\ alicloud_api_gateway_app_attachment
|
||||||
\ alicloud_api_gateway_group
|
\ alicloud_api_gateway_group
|
||||||
\ alicloud_api_gateway_vpc_access
|
\ alicloud_api_gateway_vpc_access
|
||||||
|
\ alicloud_cas_certificate
|
||||||
\ alicloud_cdn_domain
|
\ alicloud_cdn_domain
|
||||||
|
\ alicloud_cdn_domain_config
|
||||||
|
\ alicloud_cdn_domain_new
|
||||||
\ alicloud_cen_bandwidth_limit
|
\ alicloud_cen_bandwidth_limit
|
||||||
\ alicloud_cen_bandwidth_package
|
\ alicloud_cen_bandwidth_package
|
||||||
\ alicloud_cen_bandwidth_package_attachment
|
\ alicloud_cen_bandwidth_package_attachment
|
||||||
\ alicloud_cen_instance
|
\ alicloud_cen_instance
|
||||||
\ alicloud_cen_instance_attachment
|
\ alicloud_cen_instance_attachment
|
||||||
|
\ alicloud_cen_instance_grant
|
||||||
\ alicloud_cen_route_entry
|
\ alicloud_cen_route_entry
|
||||||
\ alicloud_cms_alarm
|
\ alicloud_cms_alarm
|
||||||
\ alicloud_common_bandwidth_package
|
\ alicloud_common_bandwidth_package
|
||||||
\ alicloud_common_bandwidth_package_attachment
|
\ alicloud_common_bandwidth_package_attachment
|
||||||
\ alicloud_container_cluster
|
\ alicloud_container_cluster
|
||||||
|
\ alicloud_cr_namespace
|
||||||
|
\ alicloud_cr_repo
|
||||||
\ alicloud_cs_application
|
\ alicloud_cs_application
|
||||||
\ alicloud_cs_kubernetes
|
\ alicloud_cs_kubernetes
|
||||||
\ alicloud_cs_managed_kubernetes
|
\ alicloud_cs_managed_kubernetes
|
||||||
@@ -946,6 +1031,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ alicloud_db_instance
|
\ alicloud_db_instance
|
||||||
\ alicloud_db_read_write_splitting_connection
|
\ alicloud_db_read_write_splitting_connection
|
||||||
\ alicloud_db_readonly_instance
|
\ alicloud_db_readonly_instance
|
||||||
|
\ alicloud_ddoscoo_instance
|
||||||
\ alicloud_disk
|
\ alicloud_disk
|
||||||
\ alicloud_disk_attachment
|
\ alicloud_disk_attachment
|
||||||
\ alicloud_dns
|
\ alicloud_dns
|
||||||
@@ -983,6 +1069,11 @@ syn keyword terraResourceTypeBI
|
|||||||
\ alicloud_mns_queue
|
\ alicloud_mns_queue
|
||||||
\ alicloud_mns_topic
|
\ alicloud_mns_topic
|
||||||
\ alicloud_mns_topic_subscription
|
\ alicloud_mns_topic_subscription
|
||||||
|
\ alicloud_mongodb_instance
|
||||||
|
\ alicloud_nas_access_group
|
||||||
|
\ alicloud_nas_access_rule
|
||||||
|
\ alicloud_nas_file_system
|
||||||
|
\ alicloud_nas_mount_target
|
||||||
\ alicloud_nat_gateway
|
\ alicloud_nat_gateway
|
||||||
\ alicloud_network_interface
|
\ alicloud_network_interface
|
||||||
\ alicloud_network_interface_attachment
|
\ alicloud_network_interface_attachment
|
||||||
@@ -1077,9 +1168,11 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_appmesh_route
|
\ aws_appmesh_route
|
||||||
\ aws_appmesh_virtual_node
|
\ aws_appmesh_virtual_node
|
||||||
\ aws_appmesh_virtual_router
|
\ aws_appmesh_virtual_router
|
||||||
|
\ aws_appmesh_virtual_service
|
||||||
\ aws_appsync_api_key
|
\ aws_appsync_api_key
|
||||||
\ aws_appsync_datasource
|
\ aws_appsync_datasource
|
||||||
\ aws_appsync_graphql_api
|
\ aws_appsync_graphql_api
|
||||||
|
\ aws_appsync_resolver
|
||||||
\ aws_athena_database
|
\ aws_athena_database
|
||||||
\ aws_athena_named_query
|
\ aws_athena_named_query
|
||||||
\ aws_autoscaling_attachment
|
\ aws_autoscaling_attachment
|
||||||
@@ -1088,6 +1181,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_autoscaling_notification
|
\ aws_autoscaling_notification
|
||||||
\ aws_autoscaling_policy
|
\ aws_autoscaling_policy
|
||||||
\ aws_autoscaling_schedule
|
\ aws_autoscaling_schedule
|
||||||
|
\ aws_backup_plan
|
||||||
\ aws_backup_vault
|
\ aws_backup_vault
|
||||||
\ aws_batch_compute_environment
|
\ aws_batch_compute_environment
|
||||||
\ aws_batch_job_definition
|
\ aws_batch_job_definition
|
||||||
@@ -1095,6 +1189,8 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_budgets_budget
|
\ aws_budgets_budget
|
||||||
\ aws_cloud9_environment_ec2
|
\ aws_cloud9_environment_ec2
|
||||||
\ aws_cloudformation_stack
|
\ aws_cloudformation_stack
|
||||||
|
\ aws_cloudformation_stack_set
|
||||||
|
\ aws_cloudformation_stack_set_instance
|
||||||
\ aws_cloudfront_distribution
|
\ aws_cloudfront_distribution
|
||||||
\ aws_cloudfront_origin_access_identity
|
\ aws_cloudfront_origin_access_identity
|
||||||
\ aws_cloudfront_public_key
|
\ aws_cloudfront_public_key
|
||||||
@@ -1240,6 +1336,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_glacier_vault
|
\ aws_glacier_vault
|
||||||
\ aws_glacier_vault_lock
|
\ aws_glacier_vault_lock
|
||||||
\ aws_globalaccelerator_accelerator
|
\ aws_globalaccelerator_accelerator
|
||||||
|
\ aws_globalaccelerator_listener
|
||||||
\ aws_glue_catalog_database
|
\ aws_glue_catalog_database
|
||||||
\ aws_glue_catalog_table
|
\ aws_glue_catalog_table
|
||||||
\ aws_glue_classifier
|
\ aws_glue_classifier
|
||||||
@@ -1249,6 +1346,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_glue_security_configuration
|
\ aws_glue_security_configuration
|
||||||
\ aws_glue_trigger
|
\ aws_glue_trigger
|
||||||
\ aws_guardduty_detector
|
\ aws_guardduty_detector
|
||||||
|
\ aws_guardduty_invite_accepter
|
||||||
\ aws_guardduty_ipset
|
\ aws_guardduty_ipset
|
||||||
\ aws_guardduty_member
|
\ aws_guardduty_member
|
||||||
\ aws_guardduty_threatintelset
|
\ aws_guardduty_threatintelset
|
||||||
@@ -1293,6 +1391,8 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_kinesis_firehose_delivery_stream
|
\ aws_kinesis_firehose_delivery_stream
|
||||||
\ aws_kinesis_stream
|
\ aws_kinesis_stream
|
||||||
\ aws_kms_alias
|
\ aws_kms_alias
|
||||||
|
\ aws_kms_ciphertext
|
||||||
|
\ aws_kms_external_key
|
||||||
\ aws_kms_grant
|
\ aws_kms_grant
|
||||||
\ aws_kms_key
|
\ aws_kms_key
|
||||||
\ aws_lambda_alias
|
\ aws_lambda_alias
|
||||||
@@ -1394,6 +1494,9 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_route53_health_check
|
\ aws_route53_health_check
|
||||||
\ aws_route53_query_log
|
\ aws_route53_query_log
|
||||||
\ aws_route53_record
|
\ aws_route53_record
|
||||||
|
\ aws_route53_resolver_endpoint
|
||||||
|
\ aws_route53_resolver_rule
|
||||||
|
\ aws_route53_resolver_rule_association
|
||||||
\ aws_route53_zone
|
\ aws_route53_zone
|
||||||
\ aws_route53_zone_association
|
\ aws_route53_zone_association
|
||||||
\ aws_route_table
|
\ aws_route_table
|
||||||
@@ -1406,6 +1509,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ aws_s3_bucket_object
|
\ aws_s3_bucket_object
|
||||||
\ aws_s3_bucket_policy
|
\ aws_s3_bucket_policy
|
||||||
\ aws_s3_bucket_public_access_block
|
\ aws_s3_bucket_public_access_block
|
||||||
|
\ aws_sagemaker_endpoint_configuration
|
||||||
\ aws_sagemaker_model
|
\ aws_sagemaker_model
|
||||||
\ aws_sagemaker_notebook_instance
|
\ aws_sagemaker_notebook_instance
|
||||||
\ aws_secretsmanager_secret
|
\ aws_secretsmanager_secret
|
||||||
@@ -1535,9 +1639,19 @@ syn keyword terraResourceTypeBI
|
|||||||
\ azuread_service_principal_password
|
\ azuread_service_principal_password
|
||||||
\ azuread_user
|
\ azuread_user
|
||||||
\ azurerm_api_management
|
\ azurerm_api_management
|
||||||
|
\ azurerm_api_management_api
|
||||||
|
\ azurerm_api_management_api_operation
|
||||||
|
\ azurerm_api_management_authorization_server
|
||||||
|
\ azurerm_api_management_certificate
|
||||||
\ azurerm_api_management_group
|
\ azurerm_api_management_group
|
||||||
\ azurerm_api_management_group_user
|
\ azurerm_api_management_group_user
|
||||||
|
\ azurerm_api_management_logger
|
||||||
|
\ azurerm_api_management_openid_connect_provider
|
||||||
\ azurerm_api_management_product
|
\ azurerm_api_management_product
|
||||||
|
\ azurerm_api_management_product_api
|
||||||
|
\ azurerm_api_management_product_group
|
||||||
|
\ azurerm_api_management_property
|
||||||
|
\ azurerm_api_management_subscription
|
||||||
\ azurerm_api_management_user
|
\ azurerm_api_management_user
|
||||||
\ azurerm_app_service
|
\ azurerm_app_service
|
||||||
\ azurerm_app_service_active_slot
|
\ azurerm_app_service_active_slot
|
||||||
@@ -1777,6 +1891,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ bigip_ltm_pool_attachment
|
\ bigip_ltm_pool_attachment
|
||||||
\ bigip_ltm_profile_fasthttp
|
\ bigip_ltm_profile_fasthttp
|
||||||
\ bigip_ltm_profile_fastl4
|
\ bigip_ltm_profile_fastl4
|
||||||
|
\ bigip_ltm_profile_http
|
||||||
\ bigip_ltm_profile_http2
|
\ bigip_ltm_profile_http2
|
||||||
\ bigip_ltm_profile_httpcompress
|
\ bigip_ltm_profile_httpcompress
|
||||||
\ bigip_ltm_profile_oneconnect
|
\ bigip_ltm_profile_oneconnect
|
||||||
@@ -1798,12 +1913,13 @@ syn keyword terraResourceTypeBI
|
|||||||
\ bitbucket_default_reviewers
|
\ bitbucket_default_reviewers
|
||||||
\ bitbucket_hook
|
\ bitbucket_hook
|
||||||
\ bitbucket_repository
|
\ bitbucket_repository
|
||||||
|
\ brightbox_api_client
|
||||||
\ brightbox_cloudip
|
\ brightbox_cloudip
|
||||||
\ brightbox_container
|
|
||||||
\ brightbox_database_server
|
\ brightbox_database_server
|
||||||
\ brightbox_firewall_policy
|
\ brightbox_firewall_policy
|
||||||
\ brightbox_firewall_rule
|
\ brightbox_firewall_rule
|
||||||
\ brightbox_load_balancer
|
\ brightbox_load_balancer
|
||||||
|
\ brightbox_orbit_container
|
||||||
\ brightbox_server
|
\ brightbox_server
|
||||||
\ brightbox_server_group
|
\ brightbox_server_group
|
||||||
\ chef_acl
|
\ chef_acl
|
||||||
@@ -1886,6 +2002,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ cobbler_snippet
|
\ cobbler_snippet
|
||||||
\ cobbler_system
|
\ cobbler_system
|
||||||
\ consul_agent_service
|
\ consul_agent_service
|
||||||
|
\ consul_autopilot_config
|
||||||
\ consul_catalog_entry
|
\ consul_catalog_entry
|
||||||
\ consul_intention
|
\ consul_intention
|
||||||
\ consul_key_prefix
|
\ consul_key_prefix
|
||||||
@@ -1903,6 +2020,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ datadog_timeboard
|
\ datadog_timeboard
|
||||||
\ datadog_user
|
\ datadog_user
|
||||||
\ digitalocean_certificate
|
\ digitalocean_certificate
|
||||||
|
\ digitalocean_database_cluster
|
||||||
\ digitalocean_domain
|
\ digitalocean_domain
|
||||||
\ digitalocean_droplet
|
\ digitalocean_droplet
|
||||||
\ digitalocean_droplet_snapshot
|
\ digitalocean_droplet_snapshot
|
||||||
@@ -2119,6 +2237,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ google_dataproc_cluster
|
\ google_dataproc_cluster
|
||||||
\ google_dataproc_job
|
\ google_dataproc_job
|
||||||
\ google_dns_managed_zone
|
\ google_dns_managed_zone
|
||||||
|
\ google_dns_policy
|
||||||
\ google_dns_record_set
|
\ google_dns_record_set
|
||||||
\ google_endpoints_service
|
\ google_endpoints_service
|
||||||
\ google_filestore_instance
|
\ google_filestore_instance
|
||||||
@@ -2204,6 +2323,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ google_storage_object_access_control
|
\ google_storage_object_access_control
|
||||||
\ google_storage_object_acl
|
\ google_storage_object_acl
|
||||||
\ google_storage_transfer_job
|
\ google_storage_transfer_job
|
||||||
|
\ google_tpu_node
|
||||||
\ grafana_alert_notification
|
\ grafana_alert_notification
|
||||||
\ grafana_dashboard
|
\ grafana_dashboard
|
||||||
\ grafana_data_source
|
\ grafana_data_source
|
||||||
@@ -2226,10 +2346,12 @@ syn keyword terraResourceTypeBI
|
|||||||
\ heroku_addon
|
\ heroku_addon
|
||||||
\ heroku_addon_attachment
|
\ heroku_addon_attachment
|
||||||
\ heroku_app
|
\ heroku_app
|
||||||
|
\ heroku_app_config_association
|
||||||
\ heroku_app_feature
|
\ heroku_app_feature
|
||||||
\ heroku_app_release
|
\ heroku_app_release
|
||||||
\ heroku_build
|
\ heroku_build
|
||||||
\ heroku_cert
|
\ heroku_cert
|
||||||
|
\ heroku_config
|
||||||
\ heroku_domain
|
\ heroku_domain
|
||||||
\ heroku_drain
|
\ heroku_drain
|
||||||
\ heroku_formation
|
\ heroku_formation
|
||||||
@@ -2343,11 +2465,36 @@ syn keyword terraResourceTypeBI
|
|||||||
\ influxdb_continuous_query
|
\ influxdb_continuous_query
|
||||||
\ influxdb_database
|
\ influxdb_database
|
||||||
\ influxdb_user
|
\ influxdb_user
|
||||||
|
\ jdcloud_availability_group
|
||||||
|
\ jdcloud_disk
|
||||||
|
\ jdcloud_disk_attachment
|
||||||
|
\ jdcloud_eip
|
||||||
|
\ jdcloud_eip_association
|
||||||
|
\ jdcloud_instance
|
||||||
|
\ jdcloud_instance_template
|
||||||
|
\ jdcloud_key_pairs
|
||||||
|
\ jdcloud_network_acl
|
||||||
|
\ jdcloud_network_interface
|
||||||
|
\ jdcloud_network_interface_attachment
|
||||||
|
\ jdcloud_network_security_group
|
||||||
|
\ jdcloud_network_security_group_rules
|
||||||
|
\ jdcloud_oss_bucket
|
||||||
|
\ jdcloud_oss_bucket_upload
|
||||||
|
\ jdcloud_rds_account
|
||||||
|
\ jdcloud_rds_database
|
||||||
|
\ jdcloud_rds_instance
|
||||||
|
\ jdcloud_rds_privilege
|
||||||
|
\ jdcloud_route_table
|
||||||
|
\ jdcloud_route_table_association
|
||||||
|
\ jdcloud_route_table_rules
|
||||||
|
\ jdcloud_subnet
|
||||||
|
\ jdcloud_vpc
|
||||||
\ kubernetes_cluster_role
|
\ kubernetes_cluster_role
|
||||||
\ kubernetes_cluster_role_binding
|
\ kubernetes_cluster_role_binding
|
||||||
\ kubernetes_config_map
|
\ kubernetes_config_map
|
||||||
\ kubernetes_daemonset
|
\ kubernetes_daemonset
|
||||||
\ kubernetes_deployment
|
\ kubernetes_deployment
|
||||||
|
\ kubernetes_endpoint
|
||||||
\ kubernetes_horizontal_pod_autoscaler
|
\ kubernetes_horizontal_pod_autoscaler
|
||||||
\ kubernetes_limit_range
|
\ kubernetes_limit_range
|
||||||
\ kubernetes_namespace
|
\ kubernetes_namespace
|
||||||
@@ -2393,6 +2540,15 @@ syn keyword terraResourceTypeBI
|
|||||||
\ mysql_role
|
\ mysql_role
|
||||||
\ mysql_user
|
\ mysql_user
|
||||||
\ mysql_user_password
|
\ mysql_user_password
|
||||||
|
\ ncloud_block_storage
|
||||||
|
\ ncloud_block_storage_snapshot
|
||||||
|
\ ncloud_load_balancer
|
||||||
|
\ ncloud_load_balancer_ssl_certificate
|
||||||
|
\ ncloud_login_key
|
||||||
|
\ ncloud_nas_volume
|
||||||
|
\ ncloud_port_forwarding_rule
|
||||||
|
\ ncloud_public_ip
|
||||||
|
\ ncloud_server
|
||||||
\ netlify_build_hook
|
\ netlify_build_hook
|
||||||
\ netlify_deploy_key
|
\ netlify_deploy_key
|
||||||
\ netlify_hook
|
\ netlify_hook
|
||||||
@@ -2405,6 +2561,8 @@ syn keyword terraResourceTypeBI
|
|||||||
\ newrelic_infra_alert_condition
|
\ newrelic_infra_alert_condition
|
||||||
\ newrelic_nrql_alert_condition
|
\ newrelic_nrql_alert_condition
|
||||||
\ newrelic_synthetics_alert_condition
|
\ newrelic_synthetics_alert_condition
|
||||||
|
\ newrelic_synthetics_monitor
|
||||||
|
\ newrelic_synthetics_monitor_script
|
||||||
\ nomad_acl_policy
|
\ nomad_acl_policy
|
||||||
\ nomad_acl_token
|
\ nomad_acl_token
|
||||||
\ nomad_job
|
\ nomad_job
|
||||||
@@ -2486,6 +2644,9 @@ syn keyword terraResourceTypeBI
|
|||||||
\ nutanix_virtual_machine
|
\ nutanix_virtual_machine
|
||||||
\ nutanix_volume_group
|
\ nutanix_volume_group
|
||||||
\ oci_audit_configuration
|
\ oci_audit_configuration
|
||||||
|
\ oci_autoscaling_auto_scaling_configuration
|
||||||
|
\ oci_budget_alert_rule
|
||||||
|
\ oci_budget_budget
|
||||||
\ oci_containerengine_cluster
|
\ oci_containerengine_cluster
|
||||||
\ oci_containerengine_node_pool
|
\ oci_containerengine_node_pool
|
||||||
\ oci_core_app_catalog_listing_resource_version
|
\ oci_core_app_catalog_listing_resource_version
|
||||||
@@ -2538,8 +2699,10 @@ syn keyword terraResourceTypeBI
|
|||||||
\ oci_database_autonomous_database
|
\ oci_database_autonomous_database
|
||||||
\ oci_database_autonomous_database_backup
|
\ oci_database_autonomous_database_backup
|
||||||
\ oci_database_backup
|
\ oci_database_backup
|
||||||
|
\ oci_database_data_guard_association
|
||||||
\ oci_database_db_home
|
\ oci_database_db_home
|
||||||
\ oci_database_db_system
|
\ oci_database_db_system
|
||||||
|
\ oci_database_exadata_iorm_config
|
||||||
\ oci_dns_record
|
\ oci_dns_record
|
||||||
\ oci_dns_steering_policy
|
\ oci_dns_steering_policy
|
||||||
\ oci_dns_steering_policy_attachment
|
\ oci_dns_steering_policy_attachment
|
||||||
@@ -2557,6 +2720,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ oci_health_checks_ping_probe
|
\ oci_health_checks_ping_probe
|
||||||
\ oci_identity_api_key
|
\ oci_identity_api_key
|
||||||
\ oci_identity_auth_token
|
\ oci_identity_auth_token
|
||||||
|
\ oci_identity_authentication_policy
|
||||||
\ oci_identity_compartment
|
\ oci_identity_compartment
|
||||||
\ oci_identity_customer_secret_key
|
\ oci_identity_customer_secret_key
|
||||||
\ oci_identity_dynamic_group
|
\ oci_identity_dynamic_group
|
||||||
@@ -2567,6 +2731,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ oci_identity_smtp_credential
|
\ oci_identity_smtp_credential
|
||||||
\ oci_identity_swift_password
|
\ oci_identity_swift_password
|
||||||
\ oci_identity_tag
|
\ oci_identity_tag
|
||||||
|
\ oci_identity_tag_default
|
||||||
\ oci_identity_tag_namespace
|
\ oci_identity_tag_namespace
|
||||||
\ oci_identity_ui_password
|
\ oci_identity_ui_password
|
||||||
\ oci_identity_user
|
\ oci_identity_user
|
||||||
@@ -2587,12 +2752,17 @@ syn keyword terraResourceTypeBI
|
|||||||
\ oci_load_balancer_load_balancer
|
\ oci_load_balancer_load_balancer
|
||||||
\ oci_load_balancer_path_route_set
|
\ oci_load_balancer_path_route_set
|
||||||
\ oci_load_balancer_rule_set
|
\ oci_load_balancer_rule_set
|
||||||
|
\ oci_monitoring_alarm
|
||||||
\ oci_objectstorage_bucket
|
\ oci_objectstorage_bucket
|
||||||
\ oci_objectstorage_namespace_metadata
|
\ oci_objectstorage_namespace_metadata
|
||||||
\ oci_objectstorage_object
|
\ oci_objectstorage_object
|
||||||
\ oci_objectstorage_object_lifecycle_policy
|
\ oci_objectstorage_object_lifecycle_policy
|
||||||
\ oci_objectstorage_preauthrequest
|
\ oci_objectstorage_preauthrequest
|
||||||
|
\ oci_ons_notification_topic
|
||||||
|
\ oci_ons_subscription
|
||||||
\ oci_streaming_stream
|
\ oci_streaming_stream
|
||||||
|
\ oci_waas_certificate
|
||||||
|
\ oci_waas_waas_policy
|
||||||
\ oneandone_baremetal
|
\ oneandone_baremetal
|
||||||
\ oneandone_block_storage
|
\ oneandone_block_storage
|
||||||
\ oneandone_firewall_policy
|
\ oneandone_firewall_policy
|
||||||
@@ -2821,9 +2991,11 @@ syn keyword terraResourceTypeBI
|
|||||||
\ ovh_vrack_cloudproject
|
\ ovh_vrack_cloudproject
|
||||||
\ ovh_vrack_publiccloud_attachment
|
\ ovh_vrack_publiccloud_attachment
|
||||||
\ packet_bgp_session
|
\ packet_bgp_session
|
||||||
|
\ packet_connect
|
||||||
\ packet_device
|
\ packet_device
|
||||||
\ packet_ip_attachment
|
\ packet_ip_attachment
|
||||||
\ packet_organization
|
\ packet_organization
|
||||||
|
\ packet_port_vlan_attachment
|
||||||
\ packet_project
|
\ packet_project
|
||||||
\ packet_project_ssh_key
|
\ packet_project_ssh_key
|
||||||
\ packet_reserved_ip_block
|
\ packet_reserved_ip_block
|
||||||
@@ -2984,6 +3156,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ random_shuffle
|
\ random_shuffle
|
||||||
\ random_string
|
\ random_string
|
||||||
\ random_uuid
|
\ random_uuid
|
||||||
|
\ resource_group_name
|
||||||
\ rightscale_credential
|
\ rightscale_credential
|
||||||
\ rightscale_cwf_process
|
\ rightscale_cwf_process
|
||||||
\ rightscale_deployment
|
\ rightscale_deployment
|
||||||
@@ -3138,6 +3311,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ triton_service_group
|
\ triton_service_group
|
||||||
\ triton_snapshot
|
\ triton_snapshot
|
||||||
\ triton_vlan
|
\ triton_vlan
|
||||||
|
\ ucloud_db_instance
|
||||||
\ ucloud_disk
|
\ ucloud_disk
|
||||||
\ ucloud_disk_attachment
|
\ ucloud_disk_attachment
|
||||||
\ ucloud_eip
|
\ ucloud_eip
|
||||||
@@ -3147,6 +3321,8 @@ syn keyword terraResourceTypeBI
|
|||||||
\ ucloud_lb_attachment
|
\ ucloud_lb_attachment
|
||||||
\ ucloud_lb_listener
|
\ ucloud_lb_listener
|
||||||
\ ucloud_lb_rule
|
\ ucloud_lb_rule
|
||||||
|
\ ucloud_lb_ssl
|
||||||
|
\ ucloud_lb_ssl_attachment
|
||||||
\ ucloud_security_group
|
\ ucloud_security_group
|
||||||
\ ucloud_subnet
|
\ ucloud_subnet
|
||||||
\ ucloud_udpn_connection
|
\ ucloud_udpn_connection
|
||||||
@@ -3183,6 +3359,8 @@ syn keyword terraResourceTypeBI
|
|||||||
\ vault_gcp_auth_backend
|
\ vault_gcp_auth_backend
|
||||||
\ vault_gcp_auth_backend_role
|
\ vault_gcp_auth_backend_role
|
||||||
\ vault_gcp_secret_backend
|
\ vault_gcp_secret_backend
|
||||||
|
\ vault_gcp_secret_roleset
|
||||||
|
\ vault_generic_endpoint
|
||||||
\ vault_generic_secret
|
\ vault_generic_secret
|
||||||
\ vault_github_auth_backend
|
\ vault_github_auth_backend
|
||||||
\ vault_github_team
|
\ vault_github_team
|
||||||
@@ -3191,6 +3369,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ vault_identity_entity_alias
|
\ vault_identity_entity_alias
|
||||||
\ vault_identity_group
|
\ vault_identity_group
|
||||||
\ vault_identity_group_alias
|
\ vault_identity_group_alias
|
||||||
|
\ vault_identity_group_policies
|
||||||
\ vault_jwt_auth_backend
|
\ vault_jwt_auth_backend
|
||||||
\ vault_jwt_auth_backend_role
|
\ vault_jwt_auth_backend_role
|
||||||
\ vault_kubernetes_auth_backend_config
|
\ vault_kubernetes_auth_backend_config
|
||||||
@@ -3199,6 +3378,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ vault_ldap_auth_backend_group
|
\ vault_ldap_auth_backend_group
|
||||||
\ vault_ldap_auth_backend_user
|
\ vault_ldap_auth_backend_user
|
||||||
\ vault_mount
|
\ vault_mount
|
||||||
|
\ vault_namespace
|
||||||
\ vault_okta_auth_backend
|
\ vault_okta_auth_backend
|
||||||
\ vault_okta_auth_backend_group
|
\ vault_okta_auth_backend_group
|
||||||
\ vault_okta_auth_backend_user
|
\ vault_okta_auth_backend_user
|
||||||
@@ -3217,6 +3397,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ vault_rgp_policy
|
\ vault_rgp_policy
|
||||||
\ vault_ssh_secret_backend_ca
|
\ vault_ssh_secret_backend_ca
|
||||||
\ vault_ssh_secret_backend_role
|
\ vault_ssh_secret_backend_role
|
||||||
|
\ vault_token
|
||||||
\ vault_token_auth_backend_role
|
\ vault_token_auth_backend_role
|
||||||
\ vcd_catalog
|
\ vcd_catalog
|
||||||
\ vcd_catalog_item
|
\ vcd_catalog_item
|
||||||
@@ -3224,6 +3405,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ vcd_dnat
|
\ vcd_dnat
|
||||||
\ vcd_edgegateway_vpn
|
\ vcd_edgegateway_vpn
|
||||||
\ vcd_firewall_rules
|
\ vcd_firewall_rules
|
||||||
|
\ vcd_independent_disk
|
||||||
\ vcd_inserted_media
|
\ vcd_inserted_media
|
||||||
\ vcd_network_direct
|
\ vcd_network_direct
|
||||||
\ vcd_network_isolated
|
\ vcd_network_isolated
|
||||||
@@ -3231,6 +3413,7 @@ syn keyword terraResourceTypeBI
|
|||||||
\ vcd_org
|
\ vcd_org
|
||||||
\ vcd_snat
|
\ vcd_snat
|
||||||
\ vcd_vapp
|
\ vcd_vapp
|
||||||
|
\ vcd_vapp_network
|
||||||
\ vcd_vapp_vm
|
\ vcd_vapp_vm
|
||||||
\ vsphere_compute_cluster
|
\ vsphere_compute_cluster
|
||||||
\ vsphere_compute_cluster_host_group
|
\ vsphere_compute_cluster_host_group
|
||||||
|
|||||||
@@ -176,7 +176,7 @@ if exists("typescript_enable_domhtmlcss")
|
|||||||
syntax keyword typescriptCssStyles contained border borderBottom borderLeft borderRight borderTop borderBottomColor borderLeftColor borderTopColor borderBottomStyle borderLeftStyle borderRightStyle borderTopStyle borderBottomWidth borderLeftWidth borderRightWidth borderTopWidth borderColor borderStyle borderWidth borderCollapse borderSpacing captionSide emptyCells tableLayout
|
syntax keyword typescriptCssStyles contained border borderBottom borderLeft borderRight borderTop borderBottomColor borderLeftColor borderTopColor borderBottomStyle borderLeftStyle borderRightStyle borderTopStyle borderBottomWidth borderLeftWidth borderRightWidth borderTopWidth borderColor borderStyle borderWidth borderCollapse borderSpacing captionSide emptyCells tableLayout
|
||||||
syntax keyword typescriptCssStyles contained margin marginBottom marginLeft marginRight marginTop outline outlineColor outlineStyle outlineWidth padding paddingBottom paddingLeft paddingRight paddingTop
|
syntax keyword typescriptCssStyles contained margin marginBottom marginLeft marginRight marginTop outline outlineColor outlineStyle outlineWidth padding paddingBottom paddingLeft paddingRight paddingTop
|
||||||
syntax keyword typescriptCssStyles contained listStyle listStyleImage listStylePosition listStyleType
|
syntax keyword typescriptCssStyles contained listStyle listStyleImage listStylePosition listStyleType
|
||||||
syntax keyword typescriptCssStyles contained background backgroundAttachment backgroundColor backgroundImage gackgroundPosition backgroundPositionX backgroundPositionY backgroundRepeat
|
syntax keyword typescriptCssStyles contained background backgroundAttachment backgroundColor backgroundImage backgroundPosition backgroundPositionX backgroundPositionY backgroundRepeat
|
||||||
syntax keyword typescriptCssStyles contained clear clip clipBottom clipLeft clipRight clipTop content counterIncrement counterReset cssFloat cursor direction display filter layoutGrid layoutGridChar layoutGridLine layoutGridMode layoutGridType
|
syntax keyword typescriptCssStyles contained clear clip clipBottom clipLeft clipRight clipTop content counterIncrement counterReset cssFloat cursor direction display filter layoutGrid layoutGridChar layoutGridLine layoutGridMode layoutGridType
|
||||||
syntax keyword typescriptCssStyles contained marks maxHeight maxWidth minHeight minWidth opacity MozOpacity overflow overflowX overflowY verticalAlign visibility zoom cssText
|
syntax keyword typescriptCssStyles contained marks maxHeight maxWidth minHeight minWidth opacity MozOpacity overflow overflowX overflowY verticalAlign visibility zoom cssText
|
||||||
syntax keyword typescriptCssStyles contained scrollbar3dLightColor scrollbarArrowColor scrollbarBaseColor scrollbarDarkShadowColor scrollbarFaceColor scrollbarHighlightColor scrollbarShadowColor scrollbarTrackColor
|
syntax keyword typescriptCssStyles contained scrollbar3dLightColor scrollbarArrowColor scrollbarBaseColor scrollbarDarkShadowColor scrollbarFaceColor scrollbarHighlightColor scrollbarShadowColor scrollbarTrackColor
|
||||||
|
|||||||
197
syntax/xdc.vim
Normal file
197
syntax/xdc.vim
Normal file
@@ -0,0 +1,197 @@
|
|||||||
|
if exists('g:polyglot_disabled') && index(g:polyglot_disabled, 'xdc') != -1
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Vim syntax file
|
||||||
|
" Language: XDC - Xilinx Design Constraints
|
||||||
|
" Author: Amal Khailtash <amal.khailtash@gmail.com>
|
||||||
|
" Maintainer: Amal Khailtash <amal.khailtash@gmail.com>
|
||||||
|
" Last Change: Tue, Oct 09, 2012 7:46:15 PM
|
||||||
|
" Credits: Based on SDC Vim syntax file
|
||||||
|
" Version: 1.2
|
||||||
|
" Revision Comments:
|
||||||
|
" Amal Khailtash <amal.khailtash@gmail.com> - Tue, Oct 09, 2012 7:46:15 PM
|
||||||
|
" 1.2 - Added property values and constants
|
||||||
|
" 1.1 - Cleanup
|
||||||
|
" 1.0 - Initial revision
|
||||||
|
|
||||||
|
" Quit when a syntax file was already loaded
|
||||||
|
if exists("b:current_syntax")
|
||||||
|
finish
|
||||||
|
endif
|
||||||
|
|
||||||
|
" Read the TCL syntax to start with
|
||||||
|
runtime! syntax/tcl.vim
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" SDC-specific keywords
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Operating Conditions
|
||||||
|
syntax keyword sdcOperatingConditions set_operating_conditions
|
||||||
|
|
||||||
|
" System Interface
|
||||||
|
syntax keyword sdcSystemInterface set_load
|
||||||
|
|
||||||
|
" Timing Constraints
|
||||||
|
syntax keyword sdcTimingConstraints create_clock create_generated_clock group_path
|
||||||
|
syntax keyword sdcTimingConstraints set_clock_groups set_clock_latency set_clock_sense
|
||||||
|
syntax keyword sdcTimingConstraints set_clock_uncertainty set_data_check set_disable_timing
|
||||||
|
syntax keyword sdcTimingConstraints set_input_delay set_max_time_borrow set_output_delay
|
||||||
|
syntax keyword sdcTimingConstraints set_propagated_clock
|
||||||
|
|
||||||
|
" Timing Exceptions
|
||||||
|
syntax keyword sdcTimingExceptions set_false_path set_max_delay set_min_delay set_multicycle_path
|
||||||
|
|
||||||
|
" Logic Assignments
|
||||||
|
syntax keyword sdcLogicAssignments set_case_analysis set_logic_dc set_logic_one set_logic_zero
|
||||||
|
|
||||||
|
" Design Object Access Commands
|
||||||
|
syntax keyword sdcObjectAccessCommands all_clocks all_fanin all_fanout all_inputs all_outputs
|
||||||
|
syntax keyword sdcObjectAccessCommands all_registers current_design get_cells get_clocks get_nets
|
||||||
|
syntax keyword sdcObjectAccessCommands get_pins get_ports get_timing_arcs get_timing_paths
|
||||||
|
|
||||||
|
" General Purpose Commands
|
||||||
|
syntax keyword sdcGeneralPurposeCommands current_instance set_hierarchy_separator set_units
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Unsupported SDC Commands
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Unsupported
|
||||||
|
syntax keyword sdcCollection_Unsupported foreach_in_collection
|
||||||
|
|
||||||
|
" Wire Load Models
|
||||||
|
syntax keyword sdcWireLoadModels_Unsupported set_wire_load_min_block_size set_wire_load_mode
|
||||||
|
syntax keyword sdcWireLoadModels_Unsupported set_wire_load_model set_wire_load_selection_group
|
||||||
|
|
||||||
|
" System Interface
|
||||||
|
syntax keyword sdcSystemInterface_Unsupported set_drive set_driving_cell set_fanout_load
|
||||||
|
syntax keyword sdcSystemInterface_Unsupported set_input_transition set_port_fanout_number
|
||||||
|
|
||||||
|
" Design Rule Constraints
|
||||||
|
syntax keyword sdcDesignRuleConstraints_Unsupported set_max_capacitance set_min_capacitance set_max_fanout
|
||||||
|
syntax keyword sdcDesignRuleConstraints_Unsupported set_max_transition
|
||||||
|
|
||||||
|
" Timing Constraints
|
||||||
|
syntax keyword sdcTimingConstraints_Unsupported set_clock_gating_check
|
||||||
|
syntax keyword sdcTimingConstraints_Unsupported set_clock_transition
|
||||||
|
syntax keyword sdcTimingConstraints_Unsupported set_ideal_latency set_ideal_network set_ideal_transition
|
||||||
|
syntax keyword sdcTimingConstraints_Unsupported set_resistance set_timing_derate
|
||||||
|
|
||||||
|
" Area Constraints
|
||||||
|
syntax keyword sdcAreaConstraints_Unsupported set_max_area
|
||||||
|
|
||||||
|
" Multivoltage and power optimization constraints
|
||||||
|
syntax keyword sdcMultivoltagePowerOpt_Unsupported create_voltage_area set_level_shifter_strategy
|
||||||
|
syntax keyword sdcMultivoltagePowerOpt_Unsupported set_level_shifter_threshold set_max_dynamic_power
|
||||||
|
syntax keyword sdcMultivoltagePowerOpt_Unsupported set_max_leakage_power
|
||||||
|
|
||||||
|
" Altera Unsupported
|
||||||
|
syntax keyword sdcAltera_Unsupported create_timing_netlist update_timing_netlist
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" XDC-specific extension keywords
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Operating Conditions
|
||||||
|
syntax keyword xdcOperatingConditions report_operating_conditions reset_operating_conditions
|
||||||
|
|
||||||
|
" Timing Constraints
|
||||||
|
syntax keyword xdcTimingConstraints set_input_jitter set_external_delay set_system_jitter
|
||||||
|
|
||||||
|
" Logic Assignments
|
||||||
|
syntax keyword xdcLogicAssignments set_logic_unconnected
|
||||||
|
|
||||||
|
" Design Object Access Commands
|
||||||
|
syntax keyword xdcObjectAccessCommands all_cpus all_dsps all_ffs all_hsios all_latches all_rams
|
||||||
|
syntax keyword xdcObjectAccessCommands get_generated_clocks get_iobanks get_package_pins
|
||||||
|
syntax keyword xdcObjectAccessCommands get_path_groups get_sites filter set_property
|
||||||
|
|
||||||
|
" General Purpose Commands
|
||||||
|
syntax keyword xdcGeneralPurposeCommands get_hierarchy_separator
|
||||||
|
|
||||||
|
" Floorplanning Commands
|
||||||
|
syntax keyword xdcFloorplanCommands add_cells_to_pblock create_pblock delete_pblock get_pblocks
|
||||||
|
syntax keyword xdcFloorplanCommands remove_cells_from_pblock resize_pblock
|
||||||
|
|
||||||
|
" Power-related Commands
|
||||||
|
syntax keyword xdcPowerCommands set_default_switching_activity set_power_opt
|
||||||
|
syntax keyword xdcPowerCommands set_switching_activity
|
||||||
|
|
||||||
|
" Power-related Commands
|
||||||
|
syntax keyword xdcPinPlanningCommands set_package_pin_val
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Constants
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
syntax keyword xdcConstant NO YES FALSE TRUE DISABLE ENABLE NONE BACKBONE SLOW FAST DONTCARE
|
||||||
|
syntax keyword xdcConstant NORMAL HIGH IBUF IFD BOTH HALT CONTINUE CORRECT_AND_CONTINUE
|
||||||
|
syntax keyword xdcConstant CORRECT_AND_HALT PRE_COMPUTED FIRST_READBACK
|
||||||
|
syntax keyword xdcConstant DIFF_HSTL_I DIFF_HSTL_II DIFF_HSTL_II_18 DIFF_HSTL_II_DCI
|
||||||
|
syntax keyword xdcConstant DIFF_HSTL_II_DCI_18 DIFF_HSTL_II_T_DCI DIFF_HSTL_II_T_DCI_18
|
||||||
|
syntax keyword xdcConstant DIFF_HSTL_II__T_DCI DIFF_HSTL_I_18 DIFF_HSTL_I_DCI
|
||||||
|
syntax keyword xdcConstant DIFF_HSTL_I_DCI_18 DIFF_HSUL_12_DCI DIFF_SSTL12_DCI
|
||||||
|
syntax keyword xdcConstant DIFF_SSTL12_T_DCI DIFF_SSTL135 DIFF_SSTL135_DCI DIFF_SSTL135_R
|
||||||
|
syntax keyword xdcConstant DIFF_SSTL135_T_DCI DIFF_SSTL15 DIFF_SSTL15_DCI DIFF_SSTL15_R
|
||||||
|
syntax keyword xdcConstant DIFF_SSTL15_T_DCI DIFF_SSTL18_I DIFF_SSTL18_II DIFF_SSTL18_II_DCI
|
||||||
|
syntax keyword xdcConstant DIFF_SSTL18_II_T_DCI DIFF_SSTL18_I_DCI HSLVDCI_15 HSLVDCI_18 HSTL_I
|
||||||
|
syntax keyword xdcConstant HSTL_II HSTL_II_18 HSTL_II_DCI HSTL_II_DCI_18 HSTL_II_T_DCI
|
||||||
|
syntax keyword xdcConstant HSTL_II_T_DCI_18 HSTL_I_18 HSTL_I_DCI HSTL_I_DCI_18 HSUL_12_DCI
|
||||||
|
syntax keyword xdcConstant LVCMOS12 LVCMOS18 LVCMOS25 LVDCI_15 LVDCI_18 LVDCI_DV2_15 LVDS
|
||||||
|
syntax keyword xdcConstant LVDCI_DV2_18 SSTL12_DCI SSTL12_T_DCI SSTL135 SSTL135_DCI SSTL135_R
|
||||||
|
syntax keyword xdcConstant SSTL135_T_DCI SSTL15 SSTL15_DCI SSTL15_R SSTL15_T_DCI SSTL18_I
|
||||||
|
syntax keyword xdcConstant SSTL18_II SSTL18_II_DCI SSTL18_II_T_DCI SSTL18_I_DCI
|
||||||
|
syntax keyword xdcConstant TUNED_SPLIT UNTUNED_SPLIT_25 UNTUNED_SPLIT_40 UNTUNED_SPLIT_50
|
||||||
|
syntax keyword xdcConstant UNTUNED_SPLIT_60 UNTINED_SPLIT_75 TUNED UNTUNED_25 UNTUNED_50
|
||||||
|
syntax keyword xdcConstant UNTUNED_75
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Properties
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
syntax keyword xdcProperty ASYNC_REG BEL CLOCK_DEDICATED_ROUTE COMPATIBLE_CONFIG_MODES
|
||||||
|
syntax keyword xdcProperty DCI_CASCADE DIFF_TERM DONT_TOUCH DRIVE HIODELAY_GROUP HLUTNM IN_TERM
|
||||||
|
syntax keyword xdcProperty INTERNAL_VREF IOB IODELAY_GROUP IOSTANDARD KEEP_HIERARCHY KEEPER LOC
|
||||||
|
syntax keyword xdcProperty LUTNM MARK_DEBUG OUT_TERM PACKAGE_PIN POST_CRC POST_CRC_ACTION
|
||||||
|
syntax keyword xdcProperty POST_CRC_FREQ POST_CRC_INIT_FLAG POST_CRC_SOURCE PROHIBIT PULLDOWN
|
||||||
|
syntax keyword xdcProperty PULLUP SLEW VCCAUX_IO
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Command Flags
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
syntax match xdcFlags "[[:space:]]-[[:alpha:]]*\>"
|
||||||
|
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
" Define the default highlighting.
|
||||||
|
" ----------------------------------------------------------------------------------------------------------------------
|
||||||
|
highligh default link sdcOperatingConditions Operator
|
||||||
|
highligh default link sdcSystemInterface Operator
|
||||||
|
highligh default link sdcTimingConstraints Operator
|
||||||
|
highligh default link sdcTimingExceptions Operator
|
||||||
|
highligh default link sdcLogicAssignments Operator
|
||||||
|
highligh default link sdcObjectAccessCommands Operator
|
||||||
|
highligh default link sdcGeneralPurposeCommands Operator
|
||||||
|
|
||||||
|
highligh default link sdcCollection_Unsupported WarningMsg
|
||||||
|
highligh default link sdcWireLoadModels_Unsupported WarningMsg
|
||||||
|
highligh default link sdcSystemInterface_Unsupported WarningMsg
|
||||||
|
highligh default link sdcDesignRuleConstraints_Unsupported WarningMsg
|
||||||
|
highligh default link sdcTimingConstraints_Unsupported WarningMsg
|
||||||
|
highligh default link sdcAreaConstraints_Unsupported WarningMsg
|
||||||
|
highligh default link sdcMultivoltagePowerOpt_Unsupported WarningMsg
|
||||||
|
highligh default link sdcAltera_Unsupported WarningMsg
|
||||||
|
|
||||||
|
highligh default link xdcOperatingConditions Operator
|
||||||
|
highligh default link xdcTimingConstraints Operator
|
||||||
|
highligh default link xdcLogicAssignments Operator
|
||||||
|
highligh default link xdcObjectAccessCommands Operator
|
||||||
|
highligh default link xdcGeneralPurposeCommands Operator
|
||||||
|
highligh default link xdcFloorplanCommands Operaror
|
||||||
|
highligh default link xdcPowerCommands Operaror
|
||||||
|
highligh default link xdcPinPlanningCommands Operaror
|
||||||
|
|
||||||
|
highligh default link xdcConstant Constant
|
||||||
|
highligh default link xdcProperty Type
|
||||||
|
|
||||||
|
highligh default link xdcFlags Special
|
||||||
|
|
||||||
|
let b:current_syntax = "xdc"
|
||||||
|
|
||||||
|
" vim: fileformat=unix tabstop=2 shiftwidth=2 expandtab
|
||||||
Reference in New Issue
Block a user