| Commit message (Collapse) | Author | Age |
... | |
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Some tools like clang-tidy get confused and repeat unnecessary work if
there are multiple entries with the same name.
This will only generate a compilation database for cmake version 3.20
and above. Generating a compilation database is only necessary for
development, so we don't need to maintain compatibility with the minimum
required version.
Closes https://github.com/neovim/neovim/issues/10632
|
| | |
|
| |
| |
| |
| |
| |
| |
| | |
Problem: matchaddpos() can get slow when adding many matches.
Solution: Update the next available match ID when manually picking an ID and
remove check if the available ID can be used. (idea by Rick Howe)
https://github.com/vim/vim/commit/9f573a8df02d9f699a43d2afbd1d2841d700b9ad
|
| |
| |
| |
| |
| |
| | |
Problem: matchaddpos() can only add up to 8 matches.
Solution: Allocate the array of positions. (closes vim/vim#11248)
https://github.com/vim/vim/commit/50faf02f43d7f1a56ec2023028fca7c72dbce83e
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Reverts #16271
Fixs #15913
Problem:
Since #16271, `make_filter_cmd` uses `Start-Process` cmdlet to execute the user
provided shell command for `:%!`. `Start-Process` requires the command to be
split into the shell command and its arguments. This was implemented in #19268
by parsing (splitting the user-provided command at the first space) which didn't
handle cases such as --
- commands with escaped space in their filepath
- quoted commands with space in their filepath
Solution: Use piping.
The total shell command formats (excluding noise of unimportant parameters):
1. Before #16271
```powershell
pwsh -C "(shell_cmd) < tmp.in | 2>&1 Out-File -Encoding UTF8 <tmp.out>"
# not how powershell commands work
```
2. Since #16271
```powershell
pwsh -C "Start-Process shell_cmd -RedirectStandardInput <tmp.in> -RedirectStandardOutput <tmp.out>"
# doesn't handle executable path with space in it
# doesn't write error to <tmp.out>
```
3. This PR
```powershell
pwsh -C "& { Get-Content <tmp.in> | & 'path\with space\to\shell_cmd.exe' arg1 arg2 } 2>&1 | Out-File -Encoding UTF8 <tmp.out>"
# also works with forward slash in the filepath
# also works with double quotes around shell command
```
After this PR, the user can use the following formats:
:%!c:\Program` Files\Git\usr\bin\sort.exe
:%!'c:\Program Files\Git\usr\bin\sort.exe'
:%!"c:\Program Files\Git\usr\bin\sort.exe"
:%!"c:\Program` Files\Git\usr\bin\sort.exe"
They can even chain different commands:
:%!"c:\Program` Files\Git\usr\bin\sort.exe" | sort.exe -r
But if they want to call a stringed executable path, they have to provide the
Invoke-Command operator (&). In fact, the first stringed executable path also
needs this & operator, but this PR adds that behind the scene.
:%!"c:\Program` Files\Git\usr\bin\sort.exe" | sort.exe -r | & 'c:\Program Files\Git\usr\bin\sort.exe'
## What this PR solves
- Having to parse the user-provided bang ex-command (for splitting into shell
cmd and its args).
- Removes a lot of human-unreadable `#ifdef` blocks.
- Accepting escaped spaces in executable path.
- Accepting quoted string of executable path.
- Redirects error and exception to tmp.out (exception for when `wrong_cmd.exe
not found`)
## What this PR doesn't solve
- Handling wrongly escaped path to executable, which the user may pass because
of cmdline tab-completion. #18592
## Edge cases
- (Not handled) If the user themself provides the `&` sign (means `call
this.exe` in powershell)
- (Not handled) Use `-Encoding utf8` parameter for `Get-Content`?
- (Handled) Doesn't write to tmp.out if shell command is not found.
- fix: use anonymous function (`{wrong_cmd.exe}`).
## Changes other than `make_filter_cmd()` function
- Encoding for piping to external executables. See BOM-less UTF8:
https://github.com/PowerShell/PowerShell/issues/4681
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
If the shell command passed to the filtered bang command isn't found,
the error isn't redirected to the temp.out file when shell is set to
powershell.
Solution: Use anonymous function with Invoke-Command operator (&).
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem:
`Start-Process` requires the command to be split into the shell
command and its arguments. Previously it was done by parsing, which
didn't handle cases such as
- commands with escaped space in their filepath
- quoted commands with space in their filepath
Solution:
Use
- `pwsh -Command` instead of `Start-Process`
- `Get-Content` instead of `-RedirectStandardInput`
- `Out-File` instead of `-RedirectStandardOutput`
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Highlight of char beyond line end is not correct. (Chuan Wei Foo)
Solution: Fix counting NUL as one cell. Draw one more character if the EOL
is part of the match. (closes vim/vim#7883)
https://github.com/vim/vim/commit/41f0895c6e3c7b921e3c102ad42be52b1be48018
Reorder test_search.vim to match Vim.
|
| |/
| |
| |
| |
| | |
- fix regression by #20411
- `diff.exe` is required for non-default 'diffopt' (diffopt=filler, diffopt=context, …)
- the names of some required nvim-qt DLLs changed
|
| |
| |
| |
| |
| | |
- update curl.exe (+ ca bundle), tee.exe, xxd.exe
- remove diff.exe because `diffopt=internal` is now the default
- update neovim-qt
|
| | |
|
| |\
| | |
| | | |
fix(extmarks): make virt_lines always start at 0 virtcol
|
| | | |
|
| |\ \
| | | |
| | | | |
fix(api)!: nvim_parse_cmd omit "count" "range" "reg" if not supported
|
| | | | |
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Co-authored-by: Raphael <glephunter@gmail.com>
Co-authored-by: smjonas <jonas.strittmatter@gmx.de>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
| |/ /
| | |
| | |
| | |
| | | |
Allows `nvim_cmd` to use the first argument as count for applicable
commands. Also adds support for non-String arguments to `nvim_cmd`.
|
| |\ \
| | | |
| | | | |
build(deps): require libvterm version 0.3
|
| | | | |
|
| |\ \ \
| | | | |
| | | | | |
build(deps): require libtermkey version 0.22
|
| | |/ /
| | | |
| | | |
| | | | |
Reduces #ifdef code.
|
| | | | |
|
| | | | |
|
| | | | |
|
| |\ \ \
| | | | |
| | | | | |
refactor: replace unnecessary helper functions in optionstr.c
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Replaces unnecessary helper functions in `optionstr.c` such as
`get_option_flags()`, `get_option_fullname()`, `set_option_flag()`,
`is_global_option()`, etc. with a single `get_option()` helper function
that allows direct access to the `options` array.
Also refactors `f_exists()` to use `get_varp_scope` instead of using
`get_option_tv`. This opens up the path for removing `getoptions_T`
altogether later down the line since the hidden option logic is no
longer needed.
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
I don't think using an integer as a NUL-terminated string can work on
big-endian systems, at least.
This is also not tested. Add a test.
Also fix a mistake in the docs of nvim_parse_cmd.
|
| | |/ /
| |/| |
| | | |
| | | | |
Add -Wno-strict-prototypes flag to external dependencies to suppress
cjson warnings. These needs to be fixed upstream first.
|
| | | | |
|
| |\ \ \
| | | | |
| | | | | |
fix(nvim): notify dict watchers on nvim_set_var and vim.g setter
|
| | |/ /
| | | |
| | | |
| | | |
| | | | |
Co-authored-by: bfredl <bjorn.linse@gmail.com>
Co-authored-by: Christian Clason <c.clason@uni-graz.at>
|
| | | |
| | | |
| | | |
| | | |
| | | | |
Problem: Luacheckrc file is not recognized.
Solution: Use lua filetype for luacheckrc. (closes vim/vim#11236)
https://github.com/vim/vim/commit/49c311c9b18e18c05f93728d1f8a552923a18423
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Problem: New TypeScript extensions are not recognized.
Solution: Recognize .mts and .cts files. (closes vim/vim#11237)
https://github.com/vim/vim/commit/7fc6c0e4dab4e80b9806a973936af54276468513
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Problem: GYP files are not recognized.
Solution: Recognize GYP files. (closes vim/vim#11242)
https://github.com/vim/vim/commit/d32474229213276c64cb293885a975dcb406fbc9
|
| |/ /
| | |
| | |
| | |
| | |
| | | |
Problem: Latexmkrc files are not recognized.
Solution: Use Perl filetype for latexmkrc files. (closes vim/vim#11241)
https://github.com/vim/vim/commit/cde031938537970938437cdbb235bc0da755ae4a
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
(#20359)
Problem: Extra newline in messages after a verbose shell message.
Solution: Output the newline with msg_putchar_attr(). (closes vim/vim#11233)
Make it possible to filter a screendump before comparing it.
https://github.com/vim/vim/commit/1190139ed01c27539615beea9559a88b2551daf3
Cherry-pick Test_message_more_scrolledback() from patch 9.0.0592 because
Nvim already behaves as intended.
|
| | | |
|
| | | |
|
| |\ \
| | | |
| | | | |
fix(cmdline): don't send invalid cursor with incsearch and cmdheight=0
|
| | | |
| | | |
| | | |
| | | | |
fixes #20306
|
| |/ /
| | |
| | |
| | |
| | |
| | |
| | | |
Co-authored-by: Miguel Carneiro <mcarneiromorenas@gmail.com>
Co-authored-by: Gregory Anders <greg@gpanders.com>
Co-authored-by: Raphael <glephunter@gmail.com>
Co-authored-by: C.D. MacEachern <craig.daniel.maceachern@gmail.com>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
|
| | |
| | |
| | |
| | | |
fixes #20316
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
Fix those naughty single quotes.
closes #20159
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Problem: Missing change in test.
Solution: Add the test change.
https://github.com/vim/vim/commit/124af71a28a633fa655cff41bc21d398481ce45f
vim-patch:9.0.0585: when long message test fails the error message is not visible
Problem: When long message test fails the error message is not visible.
Solution: Dump more lines.
https://github.com/vim/vim/commit/6a879878f4e1918a05244e6acd4c73c3135cf941
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When :undo! was introduced to Nvim the implementation of 'inccommand'
preview callback hasn't been fully decided yet, so not notifying buffer
update callbacks made sense for 'inccommand' preview callback in case it
needs to undo the changes itself.
Now it turns out that the undo-and-forget is done automatically for
'inccommand', so it doesn't make sense for :undo! to avoid notifying
buffer update callbacks anymore.
|
| |/ |
|
| |
| |
| |
| | |
It's confusing to mix vendored dependencies with neovim source code. A
clean separation is simpler to keep track of and simpler to document.
|
| |
| |
| |
| |
| | |
Problem: Only recognizing .m3u8 files is inconsistent.
Solution: Also matc .m3u files. (issue vim/vim#11204)
https://github.com/vim/vim/commit/b9725bc7f6427654eb4e35874034b0ec1b6b96b3
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Problem:
Cannot opt-out of "WARNING: The file has been changed since reading
it!!!", even with ":write!".
Solution:
Change ":write!" to skip the warning.
closes #7270
|