Problem: getcompletion() does not work properly when 'wildoptions
contains "fuzzy".
Solution: Do not use addstar(). (Yegappan Lakshmanan, closesvim/vim#9992,
closesvim/vim#9986)
e7dd0fa2c6
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Crash when using fuzzy completion.
Solution: Temporary fix: put back regexp. (closesvim/vim#9852, closesvim/vim#9851)
00333cb3b3
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Crash when using fuzzy completion.
Solution: Temporary fix: put back regexp. (closesvim/vim#9851)
29ab6ce9f3
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Fuzzy cmdline completion does not work for lower case.
Solution: Also use fuzzy completion for lower case input. (Yegappan
Lakshmanan, closesvim/vim#9849)
4df5b33f20
Initialize "regmatch" to avoid using uninitialized memory.
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Fuzzy completion does not order matches properly.
Solution: Do not use regular expression match. (Yegappan Lakshmanan,
closesvim/vim#9843)
5ec633b9b0
Nvim's ExpandGeneric() was refactored to eliminate looping for "round",
so the patch has been adapted.
fuzzy_match_str() change was already applied earlier.
In Test_wildoptions_fuzzy(), test for NvimParenthesis over MatchParen
for :syntax list, as the fuzzy matching algorithm prefers the former
(even in Vim).
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Completion only uses strict matching.
Solution: Add the "fuzzy" item for 'wildoptions'. (Yegappan Lakshmanan,
closesvim/vim#9803)
38b85cb4d7
Use MAX_FUZZY_MATCHES in fuzzy_match_str().
Omit fuzmatch_str_free() as it is only used on allocation failure.
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Memory is leaked in tabline click definitions since
https://github.com/neovim/neovim/pull/21008.
Solution: Add back a call to `stl_clear_click_defs()` that was lost in
the refactor PR.
Problem:
Failing Windows CI:
FAILED test/functional\options\defaults_spec.lua @ 361: XDG defaults with too long XDG variables are correctly set
test\helpers.lua:134: Pattern "Failed to start server: no such file or directory: /X/X/X" not found in log (last 10 lines): Xtest-defaults-log:
FAILED test/functional\options\defaults_spec.lua @ 435: XDG defaults with XDG variables that can be expanded are not expanded
test\helpers.lua:134: Pattern "Failed to start server: no such file or directory: %$XDG_RUNTIME_DIR%/" not found in log (last 10 lines): Xtest-defaults-log:
Solution:
The assert_log() statements are not relevant on Windows, because there
XDG_RUNTIME_DIR is not used for creating servers, it uses \\.pipe\….
Problem: Code is indented more than necessary.
Solution: Use an early return where it makes sense. (Yegappan Lakshmanan,
closesvim/vim#11819)
a41e221935
Cherry-pick check_text_or_curbuf_locked() from patch 9.0.0947.
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Allocated click function memory is lost due to
`nvim_eval_statusline()` not passing in a `StlClickRecord`.
Solution: Do not allocate click function memory if `tabtab == NULL`.
Resolve#21764, supersede #21842.
Problem:
Tests that _intentionally_ fail certain conditions cause noise in
$NVIM_LOG_FILE:
$NVIM_LOG_FILE: /home/runner/work/neovim/neovim/build/.nvimlog
(last 100 lines)
WRN 2023-01-16T18:26:27.673 T599.7799.0 unsubscribe:519: RPC: ch 1: tried to unsubscribe unknown event 'doesnotexist'
WRN 2023-01-16T18:29:00.557 ?.11151 server_start:163: Failed to start server: no such file or directory: /X/X/X/...
WRN 2023-01-16T18:33:07.269 127.0.0.1:12345 server_start:163: Failed to start server: address already in use: 127.0.0.1
...
-- Output to stderr:
module 'vim.shared' not found:
no field package.preload['vim.shared']
no file './vim/shared.lua'
no file '/home/runner/nvim-deps/usr/share/lua/5.1/vim/shared.lua'
no file '/home/runner/nvim-deps/usr/share/lua/5.1/vim/shared/init.lua'
no file '/home/runner/nvim-deps/usr/lib/lua/5.1/vim/shared.lua'
no file '/home/runner/nvim-deps/usr/lib/lua/5.1/vim/shared/init.lua'
no file './vim/shared.so'
...
E970: Failed to initialize builtin lua modules
Solution:
- Log to a private $NVIM_LOG_FILE in tests that intentionally fail and
cause ERR log messages.
- Assert that the expected messages are actually logged.
fix(column)!: ensure 'statuscolumn' works with virtual and wrapped lines
BREAKING CHANGE: In 'statuscolumn' evaluation, `v:wrap` has been
replaced by `v:virtnum`. `v:virtnum` is negative when drawing
virtual lines, zero when drawing the actual buffer line, and
positive when drawing the wrapped part of a buffer line.
Included patches:
821. By Paul "LeoNerd" Evans on 2022-12-29
Don't bother to emit the unrecognised sequence in DECRQSS response as it provides an echo roundtrip possibility
820. By Paul "LeoNerd" Evans on 2022-11-26
erase_internal() should only set fg/bg colour, resetting other attributes (especially RV)
819. By Paul "LeoNerd" Evans on 2022-11-09
Added vterm_screen_set_default_colors(), which repaints the cells in the buffer(s)
818. By Paul "LeoNerd" Evans on 2022-11-09
Permit either colour argument to be NULL to vterm_state_set_default_colors()
817. By Paul "LeoNerd" Evans on 2022-10-01
Delete the mk_wcswidth functions as they're not used; guard the CJK-wide one with an ifdef as by default we don't use it
816. By Paul "LeoNerd" Evans on 2022-10-01
Make sure to supply empty (void) prototype to functions that take no arguments in bin/vterm-ctrl.c
Problem: On tmux v3.2+, the `terminal-features` option may be used to enable RGB
capabilities over `terminal-overrides`. However, `show-messages` cannot be used
to detect if RGB capabilities are enabled using `terminal-features`.
Solution: Try to use `display-message -p #{client_termfeatures}` instead.
The returned features include "RGB" if either "RGB" is set in
`terminal-features`, or if "Tc" or "RGB" is set in `terminal-overrides` (as
before).
Nothing is returned by tmux versions older than v3.2, so fallback to checking
`show-messages` in that case.
Also, un-Vimscriptify the previous logic a bit, and change the error message to
point to using the `terminal-features` option instead for newer tmux versions.
Regression from the health.vim to .lua changes.
Unlike Vim script, Lua does not implicitly convert strings to numbers, so this
comparison threw an error.
Problem: The default fold column, as well as the 'statuscolumn', were
drawn unnecessarily/unexpectedly for virtual lines placed
with `virt_lines_leftcol` set.
Solution: Skip the column states if a virtual line with
`virt_lines_leftcol` set will be drawn.
Problem: The `'statuscolumn'` was not re-evaluated for wrapped lines,
when preceded by virtual/filler lines. There was also no way
to distinguish virtual and wrapped lines in the status column.
Solution: Make sure to rebuild the statuscolumn, and replace variable
`v:wrap` with `v:virtnum`. `v:virtnum` is negative when drawing
virtual lines, zero when drawing the actual buffer line, and
positive when drawing the wrapped part of a buffer line.
'shellxquote' Nvim default was adjusted in: 131aad953c
The use of "/s" is different than Vim, and may avoid the need for `shellxquote="&|<>()@^`.
For the other shells, Nvim intentionally does not fiddle with the
various "shell*" options if 'shell' is set by the user: if the user sets
'shell', they are expected to set other "shell*" options correctly.
(Most of this patch is intentionally dropped, it adds far too much
special-cases for almost zero purpose: ":help shell-powershell" makes it
easy to choose powershell without spreading special-cases throughout the
codebase, randomly changing slash behavior, etc.)
Problem: Shell options are not set properly for PowerShell.
Solution: Use better option defaults. (Mike Willams, closesvim/vim#8459)
127950241e
Co-authored-by: Mike Williams <mikew@globalgraphics.com>
Problem: Not enough testing for shell use.
Solution: Add a bit more testing. (Yegappan Lakshmanan, closesvim/vim#8469)
ffec6dd16a
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
Problem: Testing the shell option is incomplete and spread out.
Solution: Move shell tests to one file and increase coverage. (Yegappan
Lakshmanan, closesvim/vim#8464)
054794c20f
Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
PROBLEM:
exepath("test") should prefer ".bat" when shell=powershell.
Current behavior differs from Vim 8.2.3071.
TEST CASE:
1. in a folder which is in $PATH, create files "test" "test.bat".
- "(Get-Command test).Path test" returns "test.bat".
2. compare nvim:
nvim --clean
:set shell=powershell
:echo exepath("test")
3. should returns "path\to\test.bat" (before this patch it returns "path\to\test").
SOLUTION:
After this patch, the binary files "text.exe", "test.bat", "test.com"
will be found, but the file "test" (without any extension) will not be
found (matches Vim 8.2.3071). But powershell's `where` and
`Get-Command` _do_ find the extensionless 'test' file.
But Nvim with ":set shell=cmd.exe", doesn't find "test" either (before
and after this patch), even though `where test` returns correct path in
cmd.
- `where` is a program to find files in general, not just executable files.
-`Get-Command` returning extensionless (and thus non-executable) file is
puzzling even to Chris Dent, [PowerShell expert][1] (asked on
Discord).
[1]: https://www.amazon.com/Mastering-PowerShell-Scripting-Automate-environment-ebook/dp/B0971MG88X
Co-authored-by: Enan Ajmain <3nan.ajmain@gmail.com>
Helped-by: erw7 <erw7.github@gmail.com>
Fixes#21045
- Use the correct fd to replace stdin on windows (CONIN)
- Don't start the TUI if there are no tty fd (not a regression,
but makes sense regardless)
- De-mythologize "global input fd". it is just STDIN.
Running "make lintlua" will run both stylua and luacheck if both exist.
But this is not necessary as we already lint with stylua with the
stylua-action, so we only need to lint with luacheck on our own.
clint takes around 5-10 seconds to lint tui/terminfo_defs.h. For CI this
is negligible, but it's annoying for local development as touching
terminfo_defs.h will skyrocket lint times. Furthermore, we have no
reason to touch or modify terminfo_defs.h as it's a generated file, so
linting it shouldn't be necessary. This should speed up "make lint" by
the same amount, so around 5-10 seconds.