| Commit message (Collapse) | Author | Age |
... | |
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
(#31605)
Problem: hard to view an existing buffer in the preview window
Solution: add the :pbuffer command (Yinzuo Jiang)
Similar as `:pedit` and `:buffer` command. `:pbuffer` edits buffer [N]
from the buffer list in the preview window.
`:pbuffer` can also open special buffer, for example terminal buffer.
closes: vim/vim#16222
https://github.com/vim/vim/commit/a2a2fe841ed2efdbb1f8055f752a3a4d0988ae9d
Cherry-pick Test_popup_and_previewwindow_dump() changes from patch
9.0.0625.
Cherry-pick Run_noroom_for_newwindow_test() changes from patches
8.2.0432 and 9.0.0363.
Co-authored-by: Yinzuo Jiang <jiangyinzuo@foxmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
block mode (#31603)
Problem: exclusive selection not respected when re-selecting block mode
(Matt Ellis)
Solution: advance selection by another character when using
selection=exclusive and visual block mode
fixes: vim/vim#16202
closes: vim/vim#16219
https://github.com/vim/vim/commit/bb955894734b287abfadd3a25786a42038d18d61
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem:
- API functions using `try_start` directly, do not surface the
underlying error message, and instead show generic messages.
- Error-handling code is duplicated in the API impl.
- Failure modes are not tested.
Solution:
- Use `TRY_WRAP`.
- Add tests.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Problem:
`man -w` does not work on recent versions of MacOs.
Solution:
Make it so an empty result is interpreted as an error unless silent=true
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem:
Regression from de794f2d2409: `vim.diagnostic.setqflist{open=true}` attempts to
open the location list instead of the diagnostics quickfix list if it didn't
exist before. This is because we are using `qf_id` to decide which to open, but
`qf_id=nil` when there is no existing diagnostics quickfix list with a given
title ("Diagnostics" by default).
Solution:
- Revert to using `loclist` to decide which to open.
- Add tests.
|
|/
|
|
|
|
|
|
|
|
|
| |
Problem:
- API functions using `try_start` directly instead of `TRY_WRAP`, do not
surface the underlying error message, and instead show generic things
like "Failed to set buffer".
- Error handling code is duplicated in the API impl, instead of
delegating to the vim buffer/window handling logic.
Solution:
- Use `TRY_WRAP`.
|
|
|
|
|
|
| |
Problem: cannot handle `:undo` and `:redo` messages in a special way,
e.g. replace one by another.
Solution: add `undo` kind.
|
|
|
|
|
|
|
|
|
|
|
|
| |
## Problem
With 'winfixbuf' enabled, `nvim_win_set_buf` and `nvim_set_current_buf` fail
even if targeting the already-current buffer.
vim.wo.winfixbuf = true
vim.api.nvim_win_set_buf(0, 0)
vim.api.nvim_set_current_buf(0)
Solution:
Check for this condition.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: filetype: lalrpop files are not recognized
Solution: detect '*.lalrpop' files as lalrpop filetype
(David Thievon)
References:
https://github.com/lalrpop/lalrpop
closes: vim/vim#16223
https://github.com/vim/vim/commit/5a2e0cf5f11c611c9b01f1bd6e7294edf0dd2bf4
Co-authored-by: David Thievon <pdkfan@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: filetype: Pixi lock files are not recognized
Solution: detect "pixi.lock" file as yaml filetype
(Brandon Maier)
Reference:
https://pixi.sh/latest/features/lockfile/
closes: vim/vim#16212
https://github.com/vim/vim/commit/7d1bb90dcf711c732a49e0a45e56028a4853a17d
Co-authored-by: Brandon Maier <brandon.maier@gmail.com>
|
|
|
|
|
|
|
|
| |
Problem:
Since e049c6e4c08a, most statusline-like UI elements can combine
highlight attrs, except for sign/statuscolumn.
Solution:
Implement for sign/statuscolumn.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem:
An LSP configuration that creates client with no root_dir or
workspace_folders can result in vim.lsp.enable attaching to it multiple
times.
Solution:
When checking existing clients, reuse a client if it wasn't initially
configured have any workspace_folders. This more closely matches the
behaviour we had prior to d9235ef
|
|
|
|
|
|
|
|
|
|
|
|
| |
Problem: filetype: some assembler are files not recognized
Solution: detect '*.nasm' files as nasm filetype and '*.masm' as masm
filetype (Wu, Zhenyu)
closes: vim/vim#16194
https://github.com/vim/vim/commit/d66d68763d0947c292a9fdda4da6fda3650fa563
Co-authored-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
|
|
|
|
|
|
| |
Problem: when zindex is changed in vim.schedule the zindex sort in
layers not changed.
Solution: resort layers when zindex changed.
|
|
|
|
|
|
|
|
|
|
| |
**Problem:**
The brackets in the RFC2732 regular expression are currently unescaped,
causing them to be misinterpreted as special characters denoting
character groups rather than as literal characters.
**Solution:**
Escape the brackets.
Fix #31270
|
|
|
|
|
|
|
| |
Problem: Float preview window still exist when back at original.
Or no info item is selected.
Solution: if selected is -1 or no info is selected, if float preview
window exist close it first.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
`get_captures_at_pos()` #30559
**Problem:** Currently, it is difficult to get node(s)-level metadata
for a capture returned by `get_captures_at_pos()`. This is because it is
stored in `metadata[id]` and we do not have access to the value of `id`,
so to get this value we have to iterate over the keys of `metadata`. See
[this commit](https://github.com/neovim/neovim/commit/d63622930001b39b12f14112fc3abb55b760c447#diff-8bd4742121c2f359d0345f3c6c253a58220f1a28670cc4e1c957992232059a6cR16).
Things would be much simpler if we were given the `id` of the capture so
we could use it to just index `metadata` directly.
**Solution:** Include `id` in the data returned by
`get_captures_at_pos()`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Design goals/requirements:
- Default configuration of a server can be distributed across multiple sources.
- And via RTP discovery.
- Default configuration can be specified for all servers.
- Configuration _can_ be project specific.
Solution:
- Two new API's:
- `vim.lsp.config(name, cfg)`:
- Used to define default configurations for servers of name.
- Can be used like a table or called as a function.
- Use `vim.lsp.confg('*', cfg)` to specify default config for all
servers.
- `vim.lsp.enable(name)`
- Used to enable servers of name. Uses configuration defined
via `vim.lsp.config()`.
|
|
|
|
| |
- Problem: cannot replace the initial bufwrite message (from `filemess`) by the final one (`"test.lua" [New] 0L, 0B written`), when using `vim.ui_attach`.
- Solution: add kind to both messages.
|
|\
| |
| | |
perf(decor): improve performance for long lines
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: various vartabstop and shiftround bugs when shifting lines
Solution: Fix the bugs, add new tests for shifting lines in various ways
(Gary Johnson)
fixes: vim/vim#14891
closes: vim/vim#16193
https://github.com/vim/vim/commit/eed63f96d26723ff31a9728647eed526d06a553d
Co-authored-by: Gary Johnson <garyjohn@spocom.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: [security]: prevent overflow in indenting
Solution: use long long and remove cast to (int)
The shiftwidth option values are defined as being long. However, when
calculating the actual amount of indent, we cast down to (int), which
may cause the shiftwidth value to become negative and later it may even
cause Vim to try to allocate a huge amount of memory.
We already use long and long long variable types to calculate the indent
(and detect possible overflows), so the cast to (int) seems superfluous
and can be safely removed. So let's just remove the (int) cast and
calculate the indent using longs.
Additionally, the 'shiftwidth' option value is also used when determining
the actual 'cino' options. There it can again cause another overflow, so
make sure it is safe in parse_cino() as well.
fixes: vim/vim#13554
closes: vim/vim#13555
https://github.com/vim/vim/commit/3770574e4a70e810add9929973c51f9070c8c851
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: [security]: overflow in shift_line
Solution: allow a max indent of INT_MAX
[security]: overflow in shift_line
When shifting lines in operator pending mode and using a very large
value, we may overflow the size of integer. Fix this by using a long
variable, testing if the result would be larger than INT_MAX and if so,
indent by INT_MAX value.
Special case: We cannot use long here, since on 32bit architectures (or
on Windows?), it typically cannot take larger values than a plain int,
so we have to use long long count, decide whether the resulting
multiplication of the shiftwidth value * amount is larger than INT_MAX
and if so, we will store INT_MAX as possible larges value in the long
long count variable.
Then we can safely cast it back to int when calling the functions to set
the indent (set_indent() or change_indent()). So this should be safe.
Add a test that when using a huge value in operator pending mode for
shifting, we will shift by INT_MAX
closes: vim/vim#13535
https://github.com/vim/vim/commit/6bf131888a3d1de62bbfa8a7ea03c0ddccfd496e
Skip the test for now, as it takes too long and requires other fixes.
Co-authored-by: Christian Brabandt <cb@256bit.org>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: GVim: default font size a bit too small
Solution: increase guifont size to 12 pt on GTK builds
of gVim (matveyt).
fixes: vim/vim#16172
closes: vim/vim#16178
https://github.com/vim/vim/commit/ad3b6a3340a4ab02c1e5bc4a6d6a5fb858b671d3
Co-authored-by: matveyt <matthewtarasov@yandex.ru>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: no error check for neg values for 'messagesopt'
(after v9.1.0908)
Solution: add additional error checks and tests (h-east)
closes: vim/vim#16187
https://github.com/vim/vim/commit/65be834c30fb43abb2e41585b41eefcd2ae06c01
Nvim's getdigits() checks for overflow, so the code change isn't needed.
Co-authored-by: h-east <h.east.727@gmail.com>
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Variable name for 'messagesopt' doesn't match short name
(after v9.1.0908)
Solution: Change p_meo to p_mopt. Add more details to docs.
closes: vim/vim#16182
https://github.com/vim/vim/commit/8cc43daee1f485c9abf1de3c638cce7835b9f861
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: 'messagesopt' does not check max wait time
(after v9.1.0908)
Solution: Check for max wait value
(Shougo Matsushita)
closes: vim/vim#16183
https://github.com/vim/vim/commit/d9e9f89e0ffd6e7ce5e2a7f8f1ace5471e37c210
Co-authored-by: Shougo Matsushita <Shougo.Matsu@gmail.com>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: :sleep! not hiding the cursor is an arbitrary difference from
Vim without obvious justification, and Vim's behavior isn't
easily achievable in Nvim.
Solution: Make :sleep! hide the cursor while sleeping.
Ref:
https://github.com/neovim/neovim/commit/6a01b3fcc361960e559db459e1524418bc76dd66
https://github.com/neovim/neovim/commit/b5c0ade43790cf18f6a54858ddad30d8d9667cf9
|
|\ \
| | |
| | | |
fix(marks): check gravity at range bounds when deleting text
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Marks that are properly restored by the splice associated with
an undo edit, are unnecessarily pushed to the undo header. This
results in incorrect mark tracking in the "copy_only"
save/restore completion path.
Solution: Avoid pushing left gravity marks at the beginning of the range,
and right gravity marks at the end of the range to the undo
header.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
char-wise folding for `#trim!` ranges are improperly calculated for nodes that
end at column 0, due to the way `get_node_text` works.
Solution:
Add the blank line that `get_node_text` removes for for nodes ending at column
0. Also properly set column positions when performing linewise trims.
|
| | |
| | |
| | |
| | | |
Not used anywhere.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: not possible to configure :messages
Solution: add the 'messagesopt' option (Shougo Matsushita)
closes: vim/vim#16068
https://github.com/vim/vim/commit/51d4d84d6a7159c6ce9e04b36f8edc105ca3794b
Co-authored-by: Shougo Matsushita <Shougo.Matsu@gmail.com>
Co-authored-by: h_east <h.east.727@gmail.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
vim.json.encode escapes every slash in string values (for example in
file paths), and is not optional. Use-case is for preventing HTML
injections (eg. injecting `</script>` closing tag); in the context of
Nvim this is rarely useful.
Solution:
- Add a `escape_slash` flag to `vim.json.encode`.
- Defaults to `false`. (This is a "breaking" change, but more like
a bug fix.)
|
| | |
| | |
| | |
| | | |
The util file, for now, just abstracts the common `run_query` function.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This commit also implements more generic trimming, acting on all
whitespace (charwise) rather than just empty lines.
It will unblock
https://github.com/nvim-treesitter/nvim-treesitter/pull/3442 and allow
for properly concealing markdown bullet markers regardless of indent
width, e.g.
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: When completion leader changes, text that might be reinserted
immediately after is deleted. This unnecessarily affects
extmarks. #31387 restored the original extmarks but that
prevents end_right_gravity marks from growing.
Solution: Avoid deleting leader text that will be reinserted.
|
|/ /
| |
| |
| |
| |
| |
| |
| | |
Problem: In an autocommand Lua callback whether `args.file` is expanded
depends on whether `expand('<afile>')` has been called.
Solution: Always use the unexpanded file name for `args.file`.
Related to #31306 and vim/vim#16106. This doesn't provide `sfname`, but
at least makes `args.file` have a consistent value.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: filetype: Nvidia PTX files are not recognized
Solution: detect '*.ptx' files as ptx filetype (Yinzuo Jiang)
Reference: https://docs.nvidia.com/cuda/parallel-thread-execution/
closes: vim/vim#16171
https://github.com/vim/vim/commit/bdb5f85a5189534653f36e92b1bc780ca8d25218
Co-authored-by: Yinzuo Jiang <jiangyinzuo@foxmail.com>
|
| |
| |
| | |
- move credits and backers to credits.txt
|
| |
| |
| | |
Also remove "silent" to be more consistent with Normal mode search.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem: Missing information in CompleteDone event
Solution: add complete_word and complete_type to v:event dict
(glepnir)
closes: vim/vim#16153
https://github.com/vim/vim/commit/1c5a120a701fcf558617c4e70b5a447778f0e51d
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Before:
screen:expect({ | screen:expect({
grid = [[ | grid = [[
{10:>!}a | | line ^1 |
{7: }b | | {1:~ }|*4
{10:>>}c | | ]], messages={ {
{7: }^ | | content = { { "\ntest\n[O]k: ", 6, 11 } },
{1:~ }|*9 | kind = "confirm"
| | } }
]] | })
})
After:
screen:expect([[ | screen:expect({
{10:>!}a | | grid = [[
{7: }b | | line ^1 |
{10:>>}c | | {1:~ }|*4
{7: }^ | | ]],
{1:~ }|*9 | messages = { {
| | content = { { "\ntest\n[O]k: ", 6, 11 } },
]]) | kind = "confirm"
| } },
| })
|
|\ \ |
|