Commit Graph

9509 Commits

Author SHA1 Message Date
Samuel Huang
e3f15d5424 vim-patch:9.1.1775: filetype: Mamba configuration files are not recognized #35829
Problem:  filetype: Mamba configuration files are not recognized
Solution: Detect .mambarc and mambarc as yaml filetype (Samuel Huang).

References:
- https://mamba.readthedocs.io/en/latest/user_guide/configuration.html

closes: vim/vim#18338

21a21eafec
2025-09-18 19:41:27 -07:00
zeertzjq
67910bc99f vim-patch:e8b0e92: runtime(config): fix inconsistent group name
related: vim/vim#18292

e8b0e926d0
2025-09-19 07:42:45 +08:00
zeertzjq
f5e6c73e60 vim-patch:1e7a288: runtime(config): mark unportable += as an error
closes: vim/vim#18292

1e7a288cd3

Co-authored-by: Damien Lejay <damien@lejay.be>
2025-09-19 07:42:44 +08:00
zeertzjq
ec3dded6dd vim-patch:6701480: runtime(filetype): Use s:StarSetf for all patterns ending in * (#35825)
Problem:  Some filetype autocmds with patterns ending in * do not skip
          filenames matching g:ignored_patterns.
Solution: Move these autocmds to the appropriate section and call
          s:StarSetf() to set the filetype.

- Affected filetypes: dosini, execline, foam, messages, nginx, tmux.
- Convert foam filetype patterns to use wildcard matching.

closes: vim/vim#17422

6701480c43

Co-authored-by: Doug Kearns <dougkearns@gmail.com>
2025-09-19 06:55:00 +08:00
zeertzjq
61d7d983d6 vim-patch:9.1.1761: 'ruler' is set in defaults.vim
Problem:  'ruler' is set in defaults.vim, but not enabled by default in
          non-compatible mode.
Solution: set the ruler option in non-compatible mode, remove it from
          defaults.vim, update tests

closes: vim/vim#18260

ba36510920

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-18 08:12:44 +08:00
zeertzjq
8964ad45da vim-patch:9.1.1550: defaults: 'showcmd' is not enabled in non-compatible mode on Unix
Problem:  defaults: 'showcmd' is not enabled in non-compatible mode on
          Unix
Solution: Always enable 'showcmd' in non-compatible mode, drop it from
          defaults.vim.

'showcmd' was already always enabled in Vim compatible mode except for
UNIX environments. So let's just enable it always, there is no good
reason why UNIX platforms should be handled differently than other
platforms, especially since `defaults.vim` did enable this option
anyhow.

closes: vim/vim#17739

3f9d2378bd

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-18 08:12:31 +08:00
zeertzjq
3c480fca57 vim-patch:5bf41e7: runtime(netrw): update regex to handle remote archives (#35822)
closes: vim/vim#18318

5bf41e7418

Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
2025-09-18 08:01:33 +08:00
skewb1k
5148c1247e docs: lsp, vim_diff #35820 2025-09-17 12:29:34 -07:00
Yochem van Rosmalen
a57c7238f9 refactor(plugins)!: remove shellmenu #35815
Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
2025-09-17 11:03:58 -07:00
Yochem van Rosmalen
0bb74f0fe2 docs: standard-plugin-list #35796
The following plugins are intentionally left out:

• osc52.lua: not user-facing
• rplugin.vim: will be removed
• shellmenu: will probably be removed
2025-09-17 09:09:49 -07:00
Tomasz N
e69b81ad94 fix(lsp): treat 2-triggers-at-once as "last char wins" #35435
Problem:
If there are 2 language servers with different trigger chars (`-` and
`>`), and a keymap inputs both simultaneously (`->`), then `>` doesn't
trigger. We get completion items from server1 only.

This happens because the `completion_timer` for the `-` trigger is still
pending.

Solution:
If the next character arrived enough quickly (< 25 ms), replace the
existing deferred autotrigger with a new one that matches this later
character.
2025-09-17 09:07:45 -07:00
zeertzjq
8ec562fe52 vim-patch:684edc7: runtime(doc): mention generic log highlighter (#35812)
684edc7dce

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-17 10:13:59 +08:00
zeertzjq
da66c34a4f vim-patch:0b7d094: runtime(doc): Tweak doc style in syntax.txt (#35810)
closes: vim/vim#18310

0b7d094d70

Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
2025-09-17 10:13:43 +08:00
zeertzjq
8bc89f46b7 vim-patch:115b533: runtime(kitty): Fix typo in syntax file for kitty
closes: vim/vim#18312

115b5338da

Co-authored-by: Shawon <mdmoinulhossainshawon@gmail.com>
2025-09-17 09:08:27 +08:00
zeertzjq
72616693bd vim-patch:b2113e5: runtime(kitty): fix typo in syntax script
related: vim/vim#18280

b2113e511f

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-17 09:08:27 +08:00
zeertzjq
114336ac1d vim-patch:9.1.1763: filetype: kitty config files are not recognized
Problem:  filetype: kitty config files are not recognized
Solution: Detect */kitty/*.conf as kitty filetype, include a syntax
          script (Shawon).

closes: vim/vim#18280

a946ccf5ff

Co-authored-by: Shawon <mdmoinulhossainshawon@gmail.com>
2025-09-17 09:08:27 +08:00
zeertzjq
4ef5624729 fix(lsp): restore Client:stop() force-stopping behavior (#35800)
This fixes a regression from #33796.

I tried for several hours and cannot write a working test for this, but
this does fix the following warning in tests run with ASAN or TSAN:

    -------- Running tests from test/functional/plugin/lsp_spec.lua
    RUN      T4667 LSP server_name specified start_client(), stop_client(): 114.00 ms OK
    RUN      T4668 LSP server_name specified stop_client() also works on client objects: 97.00 ms OK
    RUN      T4669 LSP server_name specified does not reuse an already-stopping client #33616: 31.00 ms OK
    nvim took 2022 milliseconds to exit after last test
    This indicates a likely problem with the test even if it passed!
2025-09-16 20:56:09 -04:00
zeertzjq
f896f07132 vim-patch:10d1ec6: runtime(doc): fix doc style from commit 5c9b71d63c1
related: vim/vim#18265

10d1ec658c

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-16 20:58:27 +08:00
zeertzjq
051b8b88c8 vim-patch:9.1.1762: completion: selected item not cleared on <BS> with 'ac'
Problem:  completion: selected item not cleared on backspace when
          'autocomplete' is set
Solution: Clear the selected item (Girish Palya)

closes: vim/vim#18260

5c9b71d63c

Co-authored-by: Girish Palya <girishji@gmail.com>
2025-09-16 20:58:27 +08:00
zeertzjq
4f9d47bd90 vim-patch:8801c9d: runtime(m4): Improve parameters highlighting in syntax script (#35798)
closes: vim/vim#18306

8801c9db2e

Co-authored-by: Damien Lejay <damien@lejay.be>
2025-09-16 20:57:44 +08:00
zeertzjq
ff777f9a85 docs: small fixes (#35791)
Close #34938
Close #35030
Close #35233
Close #35259
Close #35290
Close #35433
Close #35541
Close #35766
Close #35792

Co-authored-by: huylg <45591413+huylg@users.noreply.github.com>
Co-authored-by: Jason Del Ponte <961963+jasdel@users.noreply.github.com>
Co-authored-by: sooriya <74165167+thuvasooriya@users.noreply.github.com>
Co-authored-by: Andrew Braxton <andrewcbraxton@gmail.com>
Co-authored-by: Enric Calabuig <enric.calabuig@gmail.com>
Co-authored-by: Augusto César Dias <augusto.c.dias@gmail.com>
Co-authored-by: David Sierra DiazGranados <davidsierradz@gmail.com>
Co-authored-by: Stepan Nikitin <90522882+vectravox@users.noreply.github.com>
Co-authored-by: Emilien Breton <bricktech2000@gmail.com>
2025-09-16 11:41:36 +08:00
zeertzjq
e7ff132708 vim-patch:9.1.1764: filetype: CODEOWNERS file not recognized (#35789)
Problem:  filetype: CODEOWNERS file not recognized
Solution: Detect CODEOWNERS file as codeowners filetype, include a
          syntax and filetype plugin (Jon Parise).

CODEOWNERS files define code ownership rules for GitHub-hosted (and
other) repositories. The syntax is similar to 'gitignore' files but
differs in enough ways to warrant its own filetype.

References:
- https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

closes: vim/vim#18299

817e4d3ee6

Co-authored-by: Jon Parise <jon@indelible.org>
2025-09-16 01:58:34 +00:00
zeertzjq
8605b0b7a9 vim-patch:9.1.{1755,1759} (#35787)
vim-patch:9.1.1755: filetype: generic log files are not recognized

Problem:  filetype: generic log files are not recognized
Solution: Detect *.log files as log filetype, include simple log syntax
          script (Mao-Yining).

closes: vim/vim#18285

b8970b43cd

vim-patch:9.1.1759: filetype: generic log detection is too disturbing

Problem:  filetype: generic log detection is too disturbing
          (after v9.1.1755)
Solution: Revert setting log filetype

48f1d6442d

Co-authored-by: Mao-Yining <mao.yining@outlook.com>
Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-16 01:35:44 +00:00
zeertzjq
cf9be1ea23 vim-patch:d4c2cb4: runtime(doc): Improve doc for cmdline-ranges in cmdline.txt (#35788)
closes: vim/vim#18278

d4c2cb4b27

Co-authored-by: Peter Kenny <github.com@k1w1.cyou>
2025-09-16 09:28:37 +08:00
skewb1k
fde0b487fb fix(lsp): avoid re-enabling document_color on registerCapability (#35774)
Problem: The registerCapability handler re-enables document_color,
making it impossible to disable it in LspAttach.

Solution: Enable it once on initialization and avoid re-enabling
on registerCapability.
2025-09-15 17:50:53 -07:00
zeertzjq
ddcfa8bb4a vim-patch:8e0d374: runtime(doc): Improve the doc for :syn-containedin (#35785)
closes: vim/vim#18290

8e0d374e4d

Co-authored-by: Damien Lejay <damien@lejay.be>
Co-authored-by: h_east <h.east.727@gmail.com>
2025-09-16 07:31:21 +08:00
Yochem van Rosmalen
47b0a718c3 feat(help): gx opens help tag in web browser #35778
Problem:
`gx` does not work on tags in help buffers to open the documentation of that tag in the browser.

Solution:
Get the `optionlink`, `taglink` and `tag` TS nodes and set extmark "url" property.
`gx` then discovers the extmark "url" and opens it.
2025-09-15 15:38:49 -07:00
zeertzjq
a5d6932686 fix(paste): don't use :echo immediately before :redraw (#35773)
- If tick == 0 at the last chunk, the first :echo will print an empty
  string, which isn't really helpful, and may cause :redraw to move
  cursor to the message area for 'showmode'.
- If tick > 0 at the last chunk, there'll be another :echo that prints
  an empty string immediately after the :redraw.
2025-09-16 06:06:02 +08:00
Yochem van Rosmalen
566e8c66f9 docs: optionlinks don't need the bars #35777
Problem:
Options links work even without vertical bars around them due to their
single quotes: the bars are unnecessary.

Solution:
Remove them.
2025-09-15 12:36:44 -07:00
zeertzjq
2debe2f30a fix(lsp): avoid automatic request after leaving insert mode (#35767)
This also fixes the following warning in tests with ASAN or TSAN:

    -------- Running tests from test/functional/plugin/lsp/inline_completion_spec.lua
    RUN      T4604 vim.lsp.inline_completion enable() requests or abort when entered/left insert mode: 225.00 ms OK
    RUN      T4605 vim.lsp.inline_completion get() applies the current candidate: 212.00 ms OK
    nvim took 2013 milliseconds to exit after last test
    This indicates a likely problem with the test even if it passed!

    RUN      T4606 vim.lsp.inline_completion get() accepts on_accept callback: 212.00 ms OK
    RUN      T4607 vim.lsp.inline_completion select() selects the next candidate: 220.00 ms OK
    -------- 4 tests from test/functional/plugin/lsp/inline_completion_spec.lua (3437.00 ms total)

    -------- Running tests from test/functional/plugin/lsp/linked_editing_range_spec.lua
    nvim took 2011 milliseconds to exit after last test
    This indicates a likely problem with the test even if it passed!
2025-09-15 14:41:29 +08:00
zeertzjq
1264d1156c fix(lua): don't leak timer when vim._watch.watch() fails (#35768)
This fixes the following warning in tests with ASAN or TSAN:

    -------- Running tests from test/functional/lua/watch_spec.lua
    RUN      T4253 vim._watch watch() ignores nonexistent paths: 29.00 ms OK
    nvim took 2006 milliseconds to exit after last test
    This indicates a likely problem with the test even if it passed!
2025-09-15 11:15:25 +08:00
zeertzjq
e2ab5e1db7 vim-patch:81ca991: runtime(html): guard against an existing b:undo_ftplugin var (#35763)
Filetype plugins should not assume they are the only file to execute on
behalf of a buffer's filetype: other filetypes may use them, and
dotted filetypes may cause multiple to run. When this occurs, they
should _build_ on their respective b:undo_ftplugin settings, not
overwrite each other.

For example, when using a dotted filetype wiki.markdown, the wiki
filetype plugins go first. Then, during the markdown filetype plugins,
the HTML plugin's unconditional assignment to b:undo_ftplugin trashes
any data previously stored there by the wiki filetype.

Follow the pattern elsewhere of assigning or appending conditionally.

closes: vim/vim#18267

81ca9916d2

Co-authored-by: D. Ben Knoble <ben.knoble+github@gmail.com>
2025-09-15 08:27:55 +08:00
zeertzjq
3f1b12c886 vim-patch:c37f25c: runtime(doc): update Markdown syntax documentation and mention Pandoc (#35762)
fixes: vim/vim#18286

c37f25c651

Co-authored-by: Mao-Yining <mao.yining@outlook.com>
2025-09-15 08:16:41 +08:00
zeertzjq
ca9cc98298 vim-patch:partial:235e77a: runtime(doc): Tweak documentation style more in options and ft_hare (#35761)
closes: 18289

235e77a3a3

Skip ft_hare.txt.

Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
2025-09-15 08:00:43 +08:00
zeertzjq
fbb1caf5f8 vim-patch:97e0f95: runtime(doc): tweak documentation style a bit more in options.txt (#35755)
related: vim/vim#18284

97e0f955da
2025-09-14 16:45:18 +08:00
skewb1k
a897cc17a5 feat(json): vim.json.encode() sort_keys #35574
Problem: There is no way to ensure a stable key order when encoding a JSON string,
which can be useful for comparisons and producing cleaner diffs.

Solution: Introduce a `sort_keys` option for `vim.json.encode()`,which
is disabled by default. When enabled, object keys are sorted in
alphabetical order.
2025-09-13 21:17:07 -07:00
Justin M. Keyes
a30a947593 docs: move editorconfig.txt into plugins.txt
It helps to have plugins living in one common area, because it signals
to users the mechanisms for controlling them, which are typically driven
by keymaps and autocmds rather than builtin options.

We can always revisit if plugins.txt gets "too big" (for example, we may
want to introduce "project.txt" for the project concept, where
editorconfig and 'exrc' are relevant), but for now it's rather unusual
for editorconfig.txt to have its own dedicated helpfile.
2025-09-13 23:23:24 -04:00
Justin M. Keyes
db67607201 docs: manpage, keycodes, json 2025-09-13 22:49:50 -04:00
Justin M. Keyes
2f78ff816b fix(lsp): misleading logs in non-applicable filetypes #35749
Problem:
LSP logs show misleading "cannot start" messages when editing a filetype
NOT listed in the `config.filetypes` field.

    [ERROR][2025-09-13 18:55:56] …/runtime//lua/vim/lsp/log.lua:151
    "cannot start cssls due to config error: …/runtime//lua/vim/lsp.lua:423:
    cmd: expected expected function or table with executable command,
    got table: 0x0104701b18. Info: vscode-css-language-server is not executable"

Solution:
- `can_start`: check `config.filetypes` before checking the rest of the
  config.
2025-09-13 18:51:06 -07:00
zeertzjq
68f40386ed vim-patch:partial:450d591: runtime(doc): tweak documentation style (#35748)
closes: vim/vim#18284

450d59145e

Skip ft_hare.txt.

Co-authored-by: Hirohito Higashi <h.east.727@gmail.com>
2025-09-13 23:33:06 +00:00
fredizzimo
8ae9a44d38 feat(ui): support grid=0 in nvim_input_mouse #32535
Problem:
Multigrid UIs have to find out which window to send the input by using
the Nvim focus rules, which are not fully documented.

Furthermore,`getmousepos()` has several problems when multigrid is
enabled, with the main one being that screenrow and screencol are window
relative instead of screen relative, due to the fact that the UI don't
send any absolute coordinates.

Solution:
Allow passing 0 as grid to `nvim_input_mouse`, with absolute
coordinates, which lets nvim determine the actual window to send the
mouse input to. This works as long as nvim is in charge of the window
positioning. If the UI repositions or resizes the windows, it can still
pass the grid it determines like before.
2025-09-13 14:57:04 -07:00
luukvbaal
c1648cf820 fix(ui): forward 'rulerformat' to msg_ruler event #35707
Problem:  A 'rulerformat' not part of the statusline is not emitted through
          msg_ruler events.
Solution: Build the message chunks to emit as a msg_ruler event.
2025-09-13 13:34:58 -07:00
Evgeni Chasnovski
a41703d107 feat(pack): confirm "Always" to install all plugins #35733
Problem: First clean start with config containing multiple
  `vim.pack.add()` calls requires to explicitly confirm each one.
  Although usually a rare occurrence, it still might be tedious.

Solution: Add a third choice during installation confirmation that
  approves current and all next installs within current session. It is
  reset after session restart.
2025-09-13 13:32:09 -07:00
Jaehwang Jung
9ce21c9cf5 vim-patch:9e100b8: runtime(netrw): only keep cursor position in tree listing mode
fixes: vim/vim#16255
closes: vim/vim#18275

9e100b8d14

Co-authored-by: Tom Benham <tom.benham13@gmail.com>
2025-09-13 13:23:36 +09:00
Jaehwang Jung
886fcad894 vim-patch:5f83674: runtime(netrw): Ensure netrw#fs#Dirname() always returns a trailing slash
closes: vim/vim#18199

5f836749fa

Co-authored-by: Miguel Barro <miguel.barro@live.com>
2025-09-13 13:23:14 +09:00
Jaehwang Jung
c318da73b4 vim-patch:5346688: runtime(netrw): fix :Explore command in terminal
There are really two issues solved here:

- The directory listing was not populating the new buffer when using
  the :Explore command. This was because the directory to open is
  determined by using expand("%:p") which includes '!/running/command' at
  the end of the string in terminal buffers.

- The :Explore command should replace the buffer, not split it. This
  because the Explore command will automatically split if the current
  buffer has been modified. According to the docs, all terminal buffers
  will have the modified flag set when a job is running.

fixes: vim/vim#9862
closes: vim/vim#18069

53466887f7

Co-authored-by: Jason Long <jasonlongball@gmail.com>
2025-09-13 13:22:47 +09:00
Jaehwang Jung
2997031732 vim-patch:6a6a44f: runtime(netrw): netrw#BrowseX() needs to distinguish local and remote file
fixes: vim/vim#17794

6a6a44ffb5

Co-authored-by: Christian Brabandt <cb@256bit.org>
2025-09-13 13:22:08 +09:00
Jaehwang Jung
130c841287 vim-patch:c849b17: runtime(netrw): Use correct "=~#" for the netrw_sizestyle='H' option
Correct expression syntax to match case in if and if-else clauses.

related: vim/vim#8535
closes: vim/vim#17901

c849b17e19

Co-authored-by: veotos <veotos@users.noreply.github.com>
2025-09-13 13:22:08 +09:00
Jaehwang Jung
cad62f5ec6 vim-patch:0bda783: runtime(netrw): upstream snapshot v184
This change includes the following upstream commits:

- fix: remove black lines in directory listing
- fix: correctly create new file when using Lexplore
- refactor: remove print functionality

The main highlight is removing print functionality that was broken both
in neovim and vim.

closes: vim/vim#17847

0bda7830ac

Co-authored-by: Luca Saccarola <github.e41mv@aleeas.com>
2025-09-13 13:19:40 +09:00
Jaehwang Jung
68c9577519 vim-patch:b3eaae2: runtime(netrw): restore blank line cleanup after file listing
Problem:  v182 refactoring removed blank line cleanup (g/^$/d) from
          s:LocalListing(), causing empty lines between directories
          and files.
Solution: Add the missing cleanup after append() in s:PerformListing()
          (uma-chan).

closes: vim/vim#17672

b3eaae21b9

Co-authored-by: uma-chan <127664533+i9wa4@users.noreply.github.com>
Co-authored-by: Luca Saccarola <96259932+saccarosium@users.noreply.github.com>
2025-09-13 13:18:24 +09:00