0
0
mirror of https://github.com/vim/vim.git synced 2025-10-18 07:54:29 -04:00
Commit Graph

5743 Commits

Author SHA1 Message Date
D. Ben Knoble
81ca9916d2 runtime(html): guard against an existing b:undo_ftplugin var
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: #18267

Signed-off-by: D. Ben Knoble <ben.knoble+github@gmail.com>
Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-14 04:42:25 -04:00
Foxe Chen
c077f5e9d8 patch 9.1.1757: The colorresp plugin causes additional redraws
Problem:  The colorresp plugin causes additional redraws
          (Linwei, after v9.1.1703)
Solution: Move the code back into the C core and get rid of the vim
          plugin (Foxe Chen)

fixes: #18251
closes: #18279

Signed-off-by: Foxe Chen <chen.foxe@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-14 04:38:33 -04:00
bennyyip
c975d62473 patch 9.1.1756: termdebug: Need a few more user commands
Problem:  termdebug: Need a few more user commands
Solution: Add the :RunOrContinue and the :ToggleBreak user commands
          (bennyyip)

closes: #18283

Signed-off-by: bennyyip <yebenmy@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-14 04:33:07 -04:00
Mao-Yining
c37f25c651 runtime(doc): update Markdown syntax documentation and mention Pandoc
fixes: #18286

Signed-off-by: Mao-Yining <mao.yining@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-14 04:28:23 -04:00
zeertzjq
97e0f955da runtime(doc): tweak documentation style a bit more in options.txt
related: #18284

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-14 04:12:12 -04:00
Mao-Yining
b8970b43cd 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: #18285

Co-authored-by: Christian Brabandt <cb@256bit.org>
Signed-off-by: Mao-Yining <mao.yining@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-14 03:59:34 -04:00
Hirohito Higashi
450d59145e runtime(doc): tweak documentation style
closes: #18284

Signed-off-by: Hirohito Higashi <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-13 10:52:36 -04:00
Doug Kearns
e8bbdb90e4 runtime(doc): Add :defe[r] shortname spec and tag
closes: #18281

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-12 10:45:34 -04:00
Girish Palya
f35a2af8ef runtime(doc): improve 'complete' option description
Add minimal reference to LSP. It might help new users.

closes: #18276

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-11 15:19:22 -04:00
Tom Benham
9e100b8d14 runtime(netrw): only keep cursor position in tree listing mode
fixes: #16255
closes: #18275

Signed-off-by: Tom Benham <tom.benham13@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-11 15:15:43 -04:00
zeertzjq
a0f37dbbf4 runtime(doc): use a single pattern in :h 'incsearch' example
related: https://github.com/vim/vim/pull/18262#issuecomment-3277008408
closes: #18270

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-11 15:08:57 -04:00
Yee Cheng Chin
976b365305 patch 9.1.1753: defaults: 'diffopt' option value can be improved
Problem:  defaults: 'diffopt' option value can be improved
Solution: Update diffopt defaults to include "indent-heuristic" and
          "inline:char" (Yee Cheng Chin)

The default diff options have not been updated much despite new
functionality having been added to Vim.

- indent-heurstic: This has been enabled by default in Git since
  33de716387 in 2017. Given that Vim uses xdiff from Git, it makes sense
  to track the default configuration from Git.

- inline:char: This turns on character-wise inline highlighting which is
  generally much better than the default inline:simple. It has been
  implemented since #16881 and we have not seen reports of any issues
  with it, and it has received good feedbacks.

closes: #18255

Signed-off-by: Yee Cheng Chin <ychin.git@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-11 15:02:21 -04:00
Maxim Kim
b49d695fbc runtime(vim): Update indent script for line continuation with lambda
fixes: #18257
closes: #18269

Signed-off-by: Maxim Kim <habamax@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-11 14:25:09 -04:00
Doug Kearns
15070eee2f runtime(python): Update syntax, fix pythonEllipsis pattern
fixes: #18263
closes: #18264

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-11 13:54:51 -04:00
Maxim Kim
5a9ef93b2c runtime(doc): Update autocmd examples for command line autocompletion
In Windows [/] should be escaped [\/]:

	autocmd CmdlineChanged [:\/\?] call wildtrigger()

This updated example works both in Linux and Windows.

closes: #18262

Signed-off-by: Maxim Kim <habamax@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-10 11:38:04 -04:00
zeertzjq
b2c8848055 runtime(doc): improve docs related to 'autocomplete'
Manual completion can still be used when 'autocomplete' is set, so
saying "active" is better than "enabled".

closes: #18261

Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-10 07:35:40 -04:00
Girish Palya
2525c56e42 patch 9.1.1750: completion: preinserted text highlighed using ComplMatchIns
Problem:  completion: preinserted text highlighed using ComplMatchIns
Solution: Use highlighting group PreInsert and update the documentation
          (Girish Palya).

When "preinsert" is included in 'completeopt', only the PreInsert
highlight group should be applied, whether autocompletion is active or not.
Previously, ComplMatchIns was used when autocompletion was not enabled.

Related to https://github.com/vim/vim/pull/18213.

closes: #18254

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-10 04:04:24 -04:00
Luna Razzaghipour
4bf0f6c1df patch 9.1.1748: macOS: Default scheduler priority too low
Problem:  macOS: Default scheduler priority too low
Solution: Explicitly set TASK_DEFAULT_APPLICATION scheduler priority
          to improve responsiveness (Luna Razzaghipour).

closes: #18120

Signed-off-by: Luna Razzaghipour <luna@xoria.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-10 03:55:51 -04:00
Girish Palya
80981e1db9 runtime(doc): mention 'findfunc' at :h :find
fixes: #18250
related: #18253

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-09 15:31:30 -04:00
Christian Brabandt
5291fe89b3 runtime(doc): mention hl-PreInsert in version9.txt
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-09 15:18:07 -04:00
Jon Parise
77cfc49060 runtime(python): highlight ellipsis literals
The ellipsis literal (`...`) can be used in multiple contexts:

- Placeholders:     `class Foo: ...`
- Containers:       `Tuple[int, ...]`
- Assignments:      `x = ...`

This is a trickier pattern to match because we can't rely on keyword
boundaries, so we instead look for exactly three dots (`...`).

This does mean that we will match the `...` portion of `x...x`, which
isn't valid Python syntax, but I think that's an acceptable trade-off
that avoids making this pattern much more complex.

Reference:
- https://docs.python.org/3/library/constants.html#Ellipsis

closes: #18107

Signed-off-by: Jon Parise <jon@indelible.org>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-08 16:29:53 -04:00
Girish Palya
d7d6a6f05a runtime(doc): Improve doc for cmdline-autocompletion
- Address https://github.com/vim/vim/pull/18219#issuecomment-3264634710
- Make the cmdline-autocompletion help more user friendly

closes: #18245

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-08 16:25:42 -04:00
rymdbar
cd9d30486a patch 9.1.1743: Haiku: no full-screen support
Problem:  Haiku: no full-screen support
Solution: Add support for toggling full-screen using the keyboard
          (rymdbar)

Makes toggling using keyboard possible. This change does not add any
`:fullscreen` command (Which currently only macVim has).

See https://www.haiku-os.org/docs/userguide/en/keyboard-shortcuts.html
for motivation on key combination used, as well as terminology choice.
With vim being inconsistent (`:help intro` suggests <A> and <M>, while
<Alt> is used at a dozen other places) following Haiku nomenclature
seems most appropriate.

closes: #18235

Signed-off-by: rymdbar <rymdbar@x20.se>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-08 15:42:25 -04:00
Amelia Clarke
6d68508e62 runtime(hare): update for Hare 0.25.2
closes: #18222

Signed-off-by: Amelia Clarke <selene@perilune.dev>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-08 15:30:41 -04:00
Doug Kearns
6bb16d2cee runtime(python): Update syntax file, fix f-string float highlighting
Fix matching of floats at the beginning of an f-string replacement
field, immediately after the opening brace.

The existing pattern, using `\zs`, cannot consume the already matched
`{` so use a lookbehind instead.

See comment: https://github.com/vim/vim/pull/17962#issuecomment-3201550443

closes: #18220

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-08 15:27:30 -04:00
Girish Palya
fa6fd41a94 patch 9.1.1742: complete: preinsert does not work well with preinsert
Problem:  complete: preinsert does not work well with preinsert
Solution: Make "preinsert" completeopt value work with autocompletion
          (Girish Palya)

This change extends Insert mode autocompletion so that 'preinsert' also
works when 'autocomplete' is enabled.

Try: `:set ac cot=preinsert`

See `:help 'cot'` for more details.

closes: #18213

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-08 15:23:29 -04:00
Damien Lejay
1ed2ff77d8 runtime(m4): Remove m4Type and leftover m4Function in syntax script
closes: #18223

Signed-off-by: Damien Lejay <damien@lejay.be>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-07 10:02:43 +02:00
Hirohito Higashi
05662b63b3 runtime(doc): Tweak spacing in develop.txt
closes: #18226

Signed-off-by: Hirohito Higashi <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-07 09:37:06 +02:00
Girish Palya
708ab7f5fb patch 9.1.1738: cmdline-autocompletion breaks history navigation
Problem:  cmdline-autocompletion breaks history navigation (ddad431)
Solution: Support history navigation in cmdline autocompletion (Girish
          Palya)

Up/Down arrows support history navigation when using wildtrigger()

fixes: #18207
closes: #18219

Signed-off-by: Girish Palya <girishji@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-06 19:54:59 +02:00
Doug Kearns
6505dc69d3 runtime(nu): Add new Nushell runtime files
See: https://github.com/elkasztano/nushell-syntax-vim

Thanks to Pete Cruz (@Petesta) for promoting this addition.

closes: #18208

Signed-off-by: Doug Kearns <dougkearns@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-06 19:31:00 +02:00
Damien Lejay
efb913a4f5 runtime(m4): Remove m4Function
closes: #18211

Signed-off-by: Damien Lejay <damien@lejay.be>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-06 15:16:06 +02:00
Snijke 1.0rc
39acad46fa runtime(colorresp): use correct load guard pattern
Signed-off-by: Snijke 1.0rc <snijke@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 21:19:24 +02:00
Christian Brabandt
dfcd9ac120 runtime(ada): mark as unmaintained, fix a few issues with the ftplugin
closes: #18178

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 21:12:05 +02:00
Christian Brabandt
f737ff8c88 runtime(hamster): do not globally set ignorecase
related: #15772

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 20:57:34 +02:00
Damien Lejay
510ca80c58 runtime(m4): Improve comments, distinguish them from #-lines
closes: #18200

Signed-off-by: Damien Lejay <damien@lejay.be>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 17:55:12 +02:00
Rob B
f1212a7b45 runtime(python): Do not match contained identifiers as pythonType
related: #17962
closes: #18206

Signed-off-by: Rob B <github@0x7e.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 16:58:35 +02:00
Miguel Barro
5f836749fa runtime(netrw): Ensure netrw#fs#Dirname() always returns a trailing slash
closes: #18199

Signed-off-by: Miguel Barro <miguel.barro@live.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 11:35:00 +02:00
Rob B
d2b28ddfc2 runtime(python): add syntax support inside f-strings
fixes: #14033
closes: #17962

Signed-off-by: Rob B <github@0x7e.net>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-05 11:28:47 +02:00
Martin Schwan
9fd1a657d2 patch 9.1.1732: filetype: .inc file detection can be improved
Problem:  filetype: .inc file detection can be improved
Solution: Update filetype detection for Pascal and BitBake code
          (Martin Schwan).

Fix the detection of .inc files containing Pascal and BitBake code:

- the concatenated string, merged from three lines, only contains one
  beginning and the pattern "^" would not match as expected. Use a range()
  loop to iterate each line string individually. This way, the pattern "^"
  works for beginning of lines.

- improve BitBake include file detection by also matching forward-slashes
  "/" in variable names and assignment operators with a dot ".=" and "=.".
  Valid examples, which should match, are:

    PREFERRED_PROVIDER_virtual/kernel = "linux-yocto"
    MACHINEOVERRIDES =. "qemuall:"
    BBPATH .= ":${LAYERDIR}"

- parse twenty instead of just three lines, to accommodate for potential
  comments at the beginning of files

closes: #18202

Signed-off-by: Martin Schwan <m.schwan@phytec.de>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-04 22:09:26 +02:00
Christian Brabandt
6d8307fc2f runtime(doc): Add a Development policy
closes: #18197

Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-04 21:56:08 +02:00
Hirohito Higashi
b2e21cccc7 runtime(doc): Tweak documentation in vi_diff.txt
closes: #18201

Signed-off-by: Hirohito Higashi <h.east.727@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-04 17:59:57 +02:00
Damien Lejay
f165798184 runtime(m4): update syntax script
This change does the following to the M4 syntax script:

- In M4 there are no "strings" in the usual sense. Instead, M4 has
  quotes, but the text inside a quoted region is rescanned just like
  outside, and quotes can be nested.
- The old m4String region was misleading and removed. A new m4Quoted
  region reflects proper quoting semantics.
- Removed a duplicate highlight rule.
- Fixed a typo in a highlight group name (m4builtin → m4Builtin).
- Added a reference link to the POSIX M4 specification.
- Removed outdated maintainer URL.

closes: #18192

Signed-off-by: Damien Lejay <damien@lejay.be>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 21:06:35 +02:00
Christian Brabandt
2d4eb6ee1f runtime(doc): Remove dead link from todo.txt
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 21:03:16 +02:00
Yochem van Rosmalen
4c39d0cc9b runtime(doc): quote partial urls with a backtick
closes: #18194

Signed-off-by: Yochem van Rosmalen <git@yochem.nl>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 20:54:14 +02:00
Andrew Radev
1acbcbc5f0 runtime(vimgoto): Implement jumping to autoloaded functions
Also refactor the script slightly.

closes: #18193

Co-authored-by: dkearns <dougkearns@gmail.com>
Signed-off-by: Andrew Radev <andrey.radev@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 20:51:43 +02:00
Wu, Zhenyu
9a6cafdc1c patch 9.1.1730: filetype: vivado journal/log files are not recognized
Problem:  filetype: vivado journal/log files are not recognized
Solution: Detect vivado*.{jou,log} as tcl filetype (Wu Zhenyu).

closes: #18191

Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 20:42:00 +02:00
Foxe Chen
5f8e31fec5 runtime(doc): remove documentation for t_Ms terminal code
as this was removed in patch: v9.1.1674

closes: #18189

Signed-off-by: Foxe Chen <chen.foxe@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 20:36:02 +02:00
Rafael Ketsetsides
e0704a3593 runtime(keymap): Add transliteration (buckwalter) arabic keymap
References:
- https://en.wikipedia.org/wiki/Buckwalter_transliteration
- http://qamus.org/transliteration.htm

closes: #18186

Signed-off-by: Rafael Ketsetsides <rketsetsides@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 20:29:49 +02:00
bennyyip
884290ebf0 patch 9.1.1728: termdebug: cannot evaluate visual selected expression
Problem:  termdebug: cannot evaluate visual selected expression
Solution: Add support for visual mode, mapped to K by default (bennyyip)

closes: #18184

Signed-off-by: bennyyip <yebenmy@gmail.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 20:06:20 +02:00
Damien Lejay
1c36a85237 patch 9.1.1727: Nextstep support still included
Problem:  Nextstep support still included
Solution: Deprecate Nextstep code and undef corresponding feature flag

closes: #18131

Signed-off-by: Damien Lejay <damien@lejay.be>
Signed-off-by: Christian Brabandt <cb@256bit.org>
2025-09-02 19:23:54 +02:00