aboutsummaryrefslogtreecommitdiff
path: root/runtime/lua/vim/_meta/api.lua
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2024-10-05 11:02:55 +0200
committerChristian Clason <c.clason@uni-graz.at>2024-10-05 11:27:05 +0200
commit988482d9422b40e86225935326127063d881b090 (patch)
tree234c61bf6e96643c59a33586039c82b492ca86af /runtime/lua/vim/_meta/api.lua
parentab98c5b5a0fdc9aad87feaf230239454f0a5e532 (diff)
downloadrneovim-988482d9422b40e86225935326127063d881b090.tar.gz
rneovim-988482d9422b40e86225935326127063d881b090.tar.bz2
rneovim-988482d9422b40e86225935326127063d881b090.zip
vim-patch:60310a4: runtime(java): Manage circularity for every :syn-included syntax file
With "g:markdown_fenced_languages" defined and "java" added to its list, a circular dependency between the Markdown and Java syntax files will be made. To break it, no Markdown documentation comments will be recognised in fenced blocks in Markdown files; in order to view Java source files, "java" must be removed from "g:markdown_fenced_languages", and this task can be automated as follows. 1) Add to "~/.after/ftplugin/java.vim": ------------------------------------------------------------ if exists("g:markdown_fenced_languages") && \ !(exists("g:java_ignore_javadoc") || \ exists("g:java_ignore_markdown")) let s:idx = index(g:markdown_fenced_languages, 'java') if s:idx > -1 call remove(g:markdown_fenced_languages, s:idx) endif unlet s:idx endif ------------------------------------------------------------ 2) Optionally add to "~/.after/ftplugin/markdown.vim": ------------------------------------------------------------ if exists("g:markdown_fenced_languages") && \ index(g:markdown_fenced_languages, 'java') < 0 call add(g:markdown_fenced_languages, 'java') endif ------------------------------------------------------------ (Make sure that the above snippets appear in the files under the "ftplugin" NOT "syntax" directory.) Finally, unless the new version of the syntax file is made available from "$VIMRUNTIME" (and from "~/.vim/syntax" if necessary), OTHER discoverable file versions will be used whose behaviour may interfere with this fix. related: vim/vim#15740 closes: vim/vim#15796 https://github.com/vim/vim/commit/60310a4b2630a4d3bb0b6da9bc03061ecfbac9ee Co-authored-by: Aliaksei Budavei <0x000c70@gmail.com>
Diffstat (limited to 'runtime/lua/vim/_meta/api.lua')
0 files changed, 0 insertions, 0 deletions