| Commit message (Collapse) | Author | Age |
|\
| |
| | |
fix(ui): propagate line flags on grid_line events
|
| |
| |
| |
| |
| |
| | |
This fixes the TUI's line-wrapping behavior, which was broken with the
migration to the msgpack-based UI protocol (see
https://github.com/neovim/neovim/issues/7369#issuecomment-1571812273).
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
perf(treesitter): cache vim.treesitter.query.get
Problem:
vim.treesitter.query.get searches and reads query files every time it's
called, if user hasn't overridden the query. So this can incur slowdown
when called frequently.
This can happen when using treesitter foldexpr. For example, when using
`:h :range!` in markdown file to format fenced codeblock, on_changedtree
in _fold.lua is triggered many times despite that the tree doesn't have
syntactic changes (might be a bug in LanguageTree). (Incidentally, the
resulting fold is incorrect due to a bug in `:h range!`.) on_changedtree
calls vim.treesitter.query.get for each tree changes. In addition, it
may request folds queries for injected languages without fold queries,
such as markdown_inline.
Solution:
* Cache the result of vim.treesitter.query.get.
* If query file was not found, fail quickly at later calls.
|
| |
| |
| | |
https://github.com/luvit/luv/releases/tag/1.45.0-0
|
| |
| |
| | |
Close #24180
|
|\ \
| | |
| | | |
feat(treesitter): add python, bash parser and queries
|
| | | |
|
| | | |
|
|/ /
| |
| |
| |
| | |
- fix lint / analysis warnings
- locations_to_items(): get default offset_encoding from active client
- character_offset(): get default offset_encoding from active client
|
| |
| |
| |
| |
| |
| |
| | |
* bundle split Markdown parser from https://github.com/MDeiml/tree-sitter-markdown
* add queries from https://github.com/nvim-treesitter/nvim-treesitter/tree/main
* upstream `#trim!` and `#inject-language!` directives
Co-authored-by: dundargoc <gocdundar@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Commit 37079fc moved inlay_hint to vim.lsp() but in the process did
missed converting a call to disable/enable which are now local.
Fixes the below error when trying to toggle inlay hints.
E5108: Error executing lua /usr/local/share/nvim/runtime/lua/vim/lsp/inlay_hint.lua:248: attempt to call field 'disable' (a nil value)
stack traceback:
/usr/local/share/nvim/runtime/lua/vim/lsp/inlay_hint.lua:248: in function 'toggle'
/usr/local/share/nvim/runtime/lua/vim/lsp/inlay_hint.lua:310: in function 'inlay_hint'
[string ":lua"]:1: in main chunk
|
|\ \
| | |
| | | |
fix(ftplugin): respect runtimepath ordering
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: bundled `ftplugin/foo/*.vim` are sourced before user
`ftplugin/foo.vim`.
Solution: call `runtime!` once on all patterns to be sourced.
Followup to #23801. Fixes #24003.
|
| | |
| | |
| | |
| | |
| | |
| | | |
Allows to keep more functions hidden and gives a path forward for
further inlay_hint related functions - like applying textEdits.
See https://github.com/neovim/neovim/pull/23984#pullrequestreview-1486624668
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
netrw uses a bespoke window to show messages.
Solution:
change the default so that netrw uses normal vim :echoerr
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
vim_lsp_inlayhint: Error executing lua: .../lsp/_inlay_hint.lua:249: attempt to index field 'applied' (a nil value)
Solution:
Assign {} to bufstates.applied in on_reload
fixes #24172
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Termdebug: error with more than 99 breakpoints.
Solution: Use a different sign for breakpoint 100 and over. (closes vim/vim#12589,
closes vim/vim#12588)
https://github.com/vim/vim/commit/e7d9ca2b3bf99b0b759be8952e02c77110a354c1
Co-authored-by: skywind3000 <skywind3000@163.com>
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Treesitter fold is not updated if treesitter hightlight is not
active. More precisely, updating folds requires `LanguageTree:parse()`.
Solution: Call `parse()` before computing folds and compute folds when
lines are added/removed.
This doesn't guarantee correctness of the folds, because some changes
that don't add/remove line won't update the folds even if they should
(e.g. adding pair of braces). But it is good enough for most cases,
while not introducing big overhead.
Also, if highlighting is active, it is likely that
`TSHighlighter._on_buf` already ran `parse()` (or vice versa).
|
| | |
| | |
| | | |
Regex bug in scripts/gen_help_html.lua:ignore_invalid()
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: PEM files are not recognized.
Solution: Add patterns to match PEM files. (closes vim/vim#12582)
https://github.com/vim/vim/commit/0256d76a3392aef270b38d1cf7633008e45c2003
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Not all cabal config files are recognized.
Solution: Add a couple of patterns. (Marcin Szamotulski, closes vim/vim#12463)
https://github.com/vim/vim/commit/166cd7b801ebe4aa042a9bbd6007d1951800aaa9
Also:
- Do not expand Lua patterns in environment variables used in file patterns.
- Test $XDG_CONFIG_HOME on Windows, as it can be used by Nvim (and the runner
sets it).
Co-authored-by: Marcin Szamotulski <coot@coot.me>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Prepare for https://github.com/neovim/tree-sitter-vimdoc/pull/108 which improves
`{arg}` highlighting in many common cases:
vim.foo({bar})
vim.foo( {bar})
nvim_foo({bar})
nvim_foo({bar},{baz})
nvim_foo({bar}, {baz})
foo[{buf}]
The tradeoff is that things like `"[{"` are flagged as parse errors.
We could avoid if we drop support for `foo[{buf}]`, but that is rather common
(see `builtin.txt`).
|
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: vimdoc parser requires space between column heading and `~`.
Solution: Add space to docs (and mention it). Also edit `luaref.txt`
headings for consistency.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
In the generated docs HTML there is too much whitespace before/after `<pre>`
blocks.
- In the old layout (fixed-width), all text in `.old-help-para` is formatted as
`white-space:pre`.
- In the new layout, when `<pre>` is at the end of a `<div>`, the margins of
both are redundant, causing too much space.
Solution:
- In the old layout, always remove `<pre>` margin.
- In the new layout, disable `<pre>` margin if it is the last child.
|
|\ \ \ |
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
gen_help_html: truncate parse-error sample text
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
recognized (#24145)
Problem: Termdebug on MS-Windows: some file names are not recognized.
Solution: Do not always change \t and \n. (Christian Brabandt,
closes vim/vim#12565, closes vim/vim#12560, closes vim/vim#12550)
https://github.com/vim/vim/commit/c9a4a8ab28da2b11856a3f08ccba2e91f46b85c3
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |/ /
|/| |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: BUCK files are not recognized.
Solution: Recognize BUCK files as "bzl". (Son Luong Ngoc, closes vim/vim#12564)
https://github.com/vim/vim/commit/b46e0f3263acd99c61df06ee3c4d1f6e0b471bc3
Co-authored-by: Son Luong Ngoc <sluongng@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
colorscheme (#24139)
Problem: Termdebug: default highlight cleared when changing colorscheme.
Solution: Use a ColorScheme autocommand. (Christian Brabandt, closes vim/vim#12566,
closes vim/vim#12555)
https://github.com/vim/vim/commit/279de0cd1f58ea520826a3dd1c5562a71157b23b
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
|\ \ \
| | | |
| | | | |
fix(filetype): correctly detect bash-fc-{id} files as "sh" (vim-patch:9.0.1644)
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Problem:
On running `zig fmt` manually, the on_lines callback and the
server both detach (for some reason), and both of them call
`clear()`. This fixes it, otherwise the second one to detach
has an error in `reset_timer` since the bufstate doesn't exist
Solution:
* exit early in clear if `bufstates[bufnr]` is nil
* set bufstatte.enabled to true on reload instead of making bufstate nil
|
| | | | |
|
| |/ /
|/| |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
The decoration provider clears the whole buffer then redraws all the hints every
time the window was redrawn. This may lead to an infinite loop.
Solution:
Store the last applied version for a line and only clear and redraw the line if
the buffer version has changed.
|
| | |
| | |
| | |
| | |
| | | |
Since https://github.com/neovim/neovim/pull/23681 there is dynamic
registration support. We should use that for new features unless there
is a good reason to turn it off.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: zserio files are not recognized.
Solution: Add a pattern for zserio files. (Dominique Pellé,
closes vim/vim#12544)
https://github.com/vim/vim/commit/2b994da57a0ac6ec0ec09fe3783f48ecd2bce610
Co-authored-by: =?UTF-8?q?Dominique=20Pell=C3=A9?= <dominique.pelle@gmail.com>
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
There is no need for two ways to access all clients of a buffer.
This doesn't add a `vim.deprecate` call yet, as the function is probably
used a lot, but removes it from the documentation and annotates it with
`@deprecated`
|
| | |
| | |
| | |
| | | |
followup to #24109
fix #16150
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Enforce consistent terminology (defined in
`gen_help_html.lua:spell_dict`) for common misspellings.
This does not spellcheck English in general (perhaps a future TODO,
though it may be noisy).
|
|\ \ \
| | | |
| | | | |
docs: lsp, fix errors, gen_help_html features
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Since https://github.com/neovim/tree-sitter-vimdoc/pull/97
the many cases of *.foo cause parser errors. But even before that, these
were erroneously highlighted as (argument), so fixing them is good.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
- quickstart
- mark lsp.txt as `new_layout`
- remove lsp-handler documentation for notifications: they don't have
handlers because they don't have server responses.
|
|/ / /
| | |
| | |
| | | |
With the title carry-over logic in the `$/progress` handler it's not
necessary to group again in vim.lsp.status
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
Since #23925, Version.build may be vim.NIL, which causes tostring() to fail:
E5108: Error executing lua E5114: Error while converting print argument #1: …/version.lua:129:
attempt to concatenate field 'build' (a userdata value)
stack traceback:
[C]: in function 'print'
[string ":lua"]:1: in main chunk
Solution:
Handle vim.NIL in Version:__tostring().
|