Commit Graph

23267 Commits

Author SHA1 Message Date
github-actions[bot]
8e28d8a370
[Backport release-0.8] fix(tutor): fix problem of failing to get buf name (#20985)
fix(tutor): fix problem of failing to get buf name

Closes https://github.com/neovim/neovim/issues/20920

(cherry picked from commit 86f2863e8f)

Co-authored-by: erw7 <erw7.github@gmail.com>
2022-11-06 19:23:34 -08:00
zeertzjq
a35efe1e4f
Merge pull request #20983 from neovim/backport-20952-to-release-0.8
[Backport release-0.8] fix(stdpath): default to /tmp if stdpath('run') cannot be created
2022-11-07 09:19:42 +08:00
zeertzjq
ca9b5687f6 fix(stdpath): default to /tmp if stdpath('run') cannot be created
(cherry picked from commit 8b30d7ab4c)
2022-11-07 01:09:00 +00:00
zeertzjq
b0cb9a8ad0
Merge pull request #20960 from neovim/backport-20959-to-release-0.8
[Backport release-0.8] fix(paste): feed keys as typed in cmdline mode
2022-11-06 12:55:30 +08:00
zeertzjq
95e1978959 fix(paste): feed keys as typed in cmdline mode
(cherry picked from commit c12add7dfa)
2022-11-06 04:43:38 +00:00
zeertzjq
2255d0fb63
Merge pull request #20915 from neovim/backport-20914-to-release-0.8
[Backport release-0.8] fix(man.lua): set modifiable before writing page
2022-11-03 09:18:01 +08:00
kevinhwang91
eefa7fbbc2 fix(man.lua): set modifiable before writing page
(cherry picked from commit 4282c8b41d)
2022-11-03 01:14:07 +00:00
zeertzjq
bd4269c6a6
Merge pull request #20872 from neovim/backport-20868-to-release-0.8
[Backport release-0.8] fix(health): correct tmux rgb verification
2022-10-30 08:06:12 +08:00
Barrett Ruth
2c374e626a fix(health): correct tmux rgb verification
(cherry picked from commit 4dbbeb0749)
2022-10-29 23:38:20 +00:00
zeertzjq
6a2dcaf6ab
Merge pull request #20871 from neovim/backport-20861-to-release-0.8
[Backport release-0.8] fix(mouse): ensure no scrolling with "ver:0" in 'mousescroll'
2022-10-30 07:24:10 +08:00
zeertzjq
747b8dac73 fix(mouse): ensure no scrolling with "ver:0" in 'mousescroll'
(cherry picked from commit b3360f0734)
2022-10-29 23:11:13 +00:00
zeertzjq
f70feadb17
Merge pull request #20870 from neovim/backport-20854-to-release-0.8
[Backport release-0.8] fix: avoid unsigned overflow in home_replace()
2022-10-30 07:06:30 +08:00
zeertzjq
06144afb71 fix: avoid unsigned overflow in home_replace()
(cherry picked from commit d3ac297554)
2022-10-29 22:50:14 +00:00
github-actions[bot]
5eab16fa24
[Backport release-0.8] docs(api): pattern is not expanded for autocommands (#20838)
docs(api): pattern is not expanded for autocommands

Problem: Unlike `:autocmd`, `nvim_create_autocommand()` does not expand
environment variables in the `pattern`, which is unexpected.

Solution: Add a note to the documentation explaining this and suggesting
using `expand()` explicitly.

(cherry picked from commit eeaf943ca3)

Co-authored-by: Christian Clason <c.clason@uni-graz.at>
2022-10-27 18:59:25 -07:00
zeertzjq
ddc0b75d53
Merge pull request #20811 from neovim/backport-20810-to-release-0.8
[Backport release-0.8] fix(spell): fix wrong cast
2022-10-26 17:34:50 +08:00
zeertzjq
7aaa0f4888 fix(spell): fix wrong cast
Fix #20787

(cherry picked from commit 0b2ef98594)
2022-10-26 09:18:45 +00:00
zeertzjq
c34ebe60be
Merge pull request #20755 from neovim/backport-20754-to-release-0.8
[Backport release-0.8] vim-patch:9.0.0806: 'langmap' works differently when there are modifiers
2022-10-21 07:12:37 +08:00
zeertzjq
06c63f50fc vim-patch:9.0.0806: 'langmap' works differently when there are modifiers
Problem:    'langmap' works differently when there are modifiers.
Solution:   Only apply 'langmap' to a character where modifiers have no
            effect. (closes vim/vim#11395, closes vim/vim#11404)
49660f5139
(cherry picked from commit e8877c4d7b)
2022-10-20 22:32:55 +00:00
github-actions[bot]
32ccb9770b
[Backport release-0.8] build: don't append git tag on release versions (#20746)
build: don't append git tag on release versions

This prevents duplicate version strings such as v0.8.0-v0.8.0.

Also change the format for git releases from v0.9.0-dev-67-g625ba79be
to v0.9.0-dev-67+g625ba79be. The neovim versions are now:

release: v0.9.0
prerelease without git info: v0.9.0-dev
prerelease with git info: v0.9.0-dev-67+g625ba79be

(cherry picked from commit 90785aafe1)

Co-authored-by: dundargoc <gocdundar@gmail.com>
2022-10-20 05:25:41 -07:00
github-actions[bot]
f73bc880f4
[Backport release-0.8] feat(docs): update parser, HTML gen (#20737)
Note: although the tolerance in help_spec.lua increased, the actual
error count with the new parser decreased by about 20%. The difference
is that the old ignore_parse_error() ignored many more errors with the
old parser.

fix https://github.com/neovim/tree-sitter-vimdoc/issues/37
fix https://github.com/neovim/tree-sitter-vimdoc/issues/44
fix https://github.com/neovim/tree-sitter-vimdoc/issues/47

(cherry picked from commit 10ae8ccbf2)
2022-10-19 06:02:01 -07:00
github-actions[bot]
f76473898d
[Backport release-0.8] build(deps): bump vimdoc (help) parser to v1.2.1 (#20736)
build(deps): bump vimdoc (help) parser to v1.2.1

(cherry picked from commit fdb15c3c3f)

Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
2022-10-19 05:14:45 -07:00
github-actions[bot]
5a14c820a9
[Backport release-0.8] docs: fix/remove invalid URLs (#20735)
docs: fix/remove invalid URLs

(cherry picked from commit ec1e71109c)

Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
2022-10-19 05:06:20 -07:00
github-actions[bot]
e7ed53286e
[Backport release-0.8] fix(highlight): link more treesitter groups by default (#20731)
fix(highlight): link more treesitter groups by default

Problem: Captures used by bundled parsers are not highlighted by default
Solution: Add links to default groups

A link is added for a capture if
* there is a default group of the same name (e.g., `@tag` -> `Tag`)
* it's used in a bundled query and doesn't have a reasonable fallback
  (e.g., `@text.literal`)

Also add all linked groups to the treesitter docs.

(cherry picked from commit 0ee8b88b10)

Co-authored-by: Christian Clason <c.clason@uni-graz.at>
2022-10-19 09:35:47 +02:00
zeertzjq
7e8662676a
Merge pull request #20730 from neovim/backport-20729-to-release-0.8
[Backport release-0.8] vim-patch:9.0.0739: mouse column not correctly used for popup_setpos
2022-10-19 12:20:50 +08:00
zeertzjq
cb086f1886 vim-patch:9.0.0739: mouse column not correctly used for popup_setpos
Problem:    Mouse column not correctly used for popup_setpos.
Solution:   Adjust off-by-one error and handle Visual line selection properly.
            (Yee Cheng Chin, closes vim/vim#11356)
17822c507c

The test_termcodes.vim test cannot be used. Use a Lua test instead.

(cherry picked from commit 72d2f5aef4)
2022-10-19 03:33:04 +00:00
zeertzjq
9234e5acd6
Merge pull request #20718 from neovim/backport-20716-to-release-0.8
[Backport release-0.8] vim-patch:9.0.0786: user command does not get number from :tab modifier
2022-10-18 21:49:37 +08:00
zeertzjq
24769cf1b5 vim-patch:9.0.0786: user command does not get number from :tab modifier
Problem:    User command does not get number from :tab modifier.
Solution:   Include the number. (closes vim/vim#11393, closes vim/vim#6901)
208567e9d7
(cherry picked from commit a43a46f1e6)
2022-10-18 12:47:19 +00:00
zeertzjq
6fe00190f0
Merge pull request #20710 from neovim/backport-20709-to-release-0.8
[Backport release-0.8] fix(qflist): avoid read of uninitialized memory
2022-10-18 10:52:26 +08:00
Mahmoud Al-Qudsi
50f756ceb2 fix(qflist): avoid read of uninitialized memory
If the call to `qf_setup_state()` in `qf_init_ext()` fails, control flow jumps
to label `qf_init_end` where a call to `qf_update_buffer()` is made with
`old_last` as a function call argument.

Prior to this patch, `old_last` would not yet have been initialized to its
default value of `NULL`, resulting in `qf_update_buffer()` attempting to compare
against its uninitialized value (quickfix.c:3882) then later forwarding it to
`qf_fill_buffer()` where the address is dereferenced and repeatedly read from/
written to for performing core qflist operations.

Depending on what the default value of `old_last` was, the results may range
from a best case scenario of neovim terminating with SIGSEGV from an attempt to
dereference an invalid pointer (quickfix.c:4056) to memory corruption if it
contained some other value that results in `qfp` being initialized from
`old_last->qf_next` (after which it is subsequently written to and read from in
a fairly arbitrary fashion).

Though extremely unlikely, it's possible for there to be security considerations
as a user can ensure that the next call to `qf_setup_state()` fails.

This patch ensures that `old_last` is NULL-assigned before control flow jumps to
`qf_init_end`.

Closes #20639.

(cherry picked from commit 8a762eba60)
2022-10-18 02:16:00 +00:00
Lewis Russell
47454d0012
[Backport release-0.8] fix(decoration): call providers in win_update() earlier (#20699)
fix(decoration): call providers in win_update() earlier

Fixes #20651

(cherry picked from commit 2921de6a96)
2022-10-18 00:14:27 +01:00
github-actions[bot]
c52d256e91
[Backport release-0.8] fix(decoration): redraw correctly when re-using ids (#20708)
Co-authored-by: Lewis Russell <lewis6991@gmail.com>
2022-10-17 22:07:49 +01:00
zeertzjq
59087b615d
Merge pull request #20701 from neovim/backport-20662-to-release-0.8
[Backport release-0.8] vim-patch:8.1.0342,9.0.{0614,0616}: SpellFileMissing autocmd may delete buffer
2022-10-17 21:40:32 +08:00
zeertzjq
89fbffff13 vim-patch:9.0.0616: spell test fails because error message changed
Problem:    Spell test fails because error message changed.
Solution:   Adjust expected error message.
371951d0c3
(cherry picked from commit a9452cf3d5)
2022-10-17 13:02:22 +00:00
zeertzjq
7ba968ef3b vim-patch:9.0.0614: SpellFileMissing autocmd may delete buffer
Problem:    SpellFileMissing autocmd may delete buffer.
Solution:   Disallow deleting the current buffer to avoid using freed memory.
ef976323e7
(cherry picked from commit 6bc2d6b66b)
2022-10-17 13:02:22 +00:00
zeertzjq
8595f0298a vim-patch:8.1.0342: crash when a callback deletes a window that is being used
Problem:    Crash when a callback deletes a window that is being used.
Solution:   Do not unload a buffer that is being displayed while redrawing the
            screen. Also avoid invoking callbacks while redrawing.
            (closes vim/vim#2107)
94f01956a5

Omit parse_queued_messages(): N/A.
Cherry-pick a break statement from patch 8.1.0425.

(cherry picked from commit 65cbe0cc35)
2022-10-17 13:02:22 +00:00
github-actions[bot]
7a011cb58d
vim-patch:9.0.0750: crash when popup closed in callback (#20660)
vim-patch:9.0.0750: crash when popup closed in callback

Problem:    Crash when popup closed in callback. (Maxim Kim)
Solution:   In syntax_end_parsing() check that syn_block is valid.
0abd6cf62d
(cherry picked from commit 2a2ae32ceb)
2022-10-15 07:31:41 +08:00
rti
5b1bda14ae
[Backport release-0.8] build(nix): change the pkgs to final, add new version of libvterm (#20640)
build(nix): change the pkgs to final, add new version of libvterm (#20410)

Co-authored-by: Philipp Herzog <philipp.herzog@protonmail.com>
2022-10-13 16:29:26 -07:00
Justin M. Keyes
1cd5361c39
Merge pull request #20617 from neovim/backport-20558-to-release-0.8
[Backport release-0.8] feat(docs-html): fixes; use tags for ToC headings
2022-10-12 09:11:56 -04:00
Justin M. Keyes
719afa2988 Merge 'upstream/release-0.8' 2022-10-12 14:23:31 +02:00
Justin M. Keyes
60ccada4cb fix duplicate tags
These are deprecated but not removed in 0.8.x.
They are removed in master / 0.9.x.
2022-10-12 14:19:46 +02:00
zeertzjq
6b49a20137
docs(lsp): vim.lsp.range_code_action() is not deprecated 2022-10-12 20:16:13 +08:00
zeertzjq
5f54cfcc05
Revert [Backport release-0.8] docs(lsp): add formatting APIs to deprecated.txt (#20614) 2022-10-12 20:10:46 +08:00
Justin M. Keyes
bca9b1ecdf feat(docs-html): try to use tags for ToC headings
Problem:
The generated ToC (table of contents) uses anchors derived from the
heading title, e.g. the "Global Plugins" heading yields:
https://neovim.io/doc/user/usr_05.html#_global-plugins-
so if the heading title changes, then the old URL (anchor) is broken.

Solution:
:help tags change less often than heading titles, so if a heading
contains a *tag*, use that as its anchor name instead. Example:
https://neovim.io/doc/user/usr_05.html#standard-plugin

(cherry picked from commit 6b01e9bf87)
2022-10-12 12:09:10 +00:00
Justin M. Keyes
5e88506508 fix(docs-html): update parser
- Improve generated HTML by updating parser which includes fixes for
  single "'" and single "|":
  https://github.com/neovim/tree-sitter-vimdoc/pull/31
- Updated parser also fixes the conceal issue for "help" highlight
  queries https://github.com/neovim/tree-sitter-vimdoc/issues/23 by
  NOT including whitespace in nodes.
  - But this means we need to restore the getws() function which scrapes
    leading whitespace from the original input (buffer).

(cherry picked from commit a7a83bc4c2)
2022-10-12 12:09:10 +00:00
github-actions[bot]
f294712d8c
[Backport release-0.8] doc (#20616)
docs: various

- increase python line-length limit from 88 => 100.
- gen_help_html: fix bug in "tag" case (tbl_count => tbl_contains)

ref #15632
fix #18215
fix #18479
fix #20527
fix #20532

Co-authored-by: Ben Weedon <ben@weedon.email>
(cherry picked from commit f37cd2bb15)

Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
2022-10-12 05:08:18 -07:00
github-actions[bot]
acb8033bca
[Backport release-0.8] docs: fix incorrect :help tag (#20615)
fix: incorrect :help tag

vim.lsp.format() doesn't exist, which causes functionaltest to fail.
Change to vim.lsp.buf.format().

(cherry picked from commit 29a7f92e2e)

Co-authored-by: dundargoc <gocdundar@gmail.com>
2022-10-12 05:04:18 -07:00
github-actions[bot]
a6b62821de
[Backport release-0.8] docs(lsp): add formatting APIs to deprecated.txt (#20614)
docs: add vim APIs to deprecated.txt

Add vim.lsp.buf.formatting() to deprecated.txt.
Add vim.lsp.buf.range_formatting() to deprecated.txt.

(cherry picked from commit a99669df1c)

Co-authored-by: steventhorne <steven.thorne91@gmail.com>
2022-10-12 05:03:09 -07:00
zeertzjq
deda165155
Merge pull request #20601 from neovim/backport-20576-to-release-0.8
[Backport release-0.8] feat(man): add health check
2022-10-12 06:24:17 +08:00
github-actions[bot]
2853284434
[Backport release-0.8] fix(runtime): properly rely on t_Co for colorschemes (#20604)
fix(runtime): properly rely on t_Co for colorschemes

Problem: check for available colors failed
Solution: simply trust t_Co, which is always available
(cherry picked from commit 5dbc713de7)

Co-authored-by: Christian Clason <c.clason@uni-graz.at>
2022-10-11 23:49:05 +02:00
Lewis Russell
62e3ca3e2b feat(man): add health check
Fixes #20432

(cherry picked from commit 4ccc57fd7a)
2022-10-11 16:01:53 +00:00