Commit Graph

23106 Commits

Author SHA1 Message Date
Matthieu Coudron
93f32bb0aa build(nix): removed the useless 'app'
the format changed depending on the nix version and it is useless
anyway.
2022-09-05 17:47:06 +02:00
zeertzjq
fb39bba5a6
Merge pull request #20088 from zeertzjq/vim-9.0.0386
vim-patch:9.0.0386: some code blocks are nested too deep

N/A patches for version.c:

vim-patch:9.0.0385: GUI: when CTRL-D is mapped in Insert mode it gets inserted
2022-09-05 23:02:01 +08:00
zeertzjq
f6a8d395a7 refactor(ex_cd): add an early return to fix clint warning
The popupmenu.c change is unrelated.
2022-09-05 22:36:09 +08:00
zeertzjq
fc7a64291a vim-patch:9.0.0386: some code blocks are nested too deep
Problem:    Some code blocks are nested too deep.
Solution:   Bail out earlier. (Yegappan Lakshmanan, closes vim/vim#11058)
b1f471ee20
2022-09-05 22:36:09 +08:00
Matthieu Coudron
8570a700cc build(nix): bumped flake 2022-09-05 11:31:24 +02:00
Matthieu Coudron
29cd072351 build(flake): add sumneko lsp in PATH
and reformatted the file
2022-09-05 11:31:22 +02:00
UnkwUsr
a220650fd6
docs(contributing): fix broken link (#20044) 2022-09-05 08:44:52 +02:00
zeertzjq
5ac6654334
Merge pull request #19481 from zeertzjq/vim-8.2.4674
Add 'mousemoveevent' as a UI option
2022-09-04 21:44:31 +08:00
zeertzjq
82d128405a feat(pum): pretend 'mousemoveevent' is set when showing right-click menu 2022-09-04 21:18:23 +08:00
zeertzjq
ceb09701f2 feat(api): add "move" to nvim_input_mouse 2022-09-04 21:18:23 +08:00
zeertzjq
04bd700ac3 feat(tui): support 'mousemoveevent' 2022-09-04 21:18:22 +08:00
zeertzjq
a5fe7940c8 feat(ui-ext): make 'mousemoveevent' a ui_option 2022-09-04 21:18:22 +08:00
zeertzjq
00b49dd8dd vim-patch:8.2.4674: cannot force getting MouseMove events
Problem:    Cannot force getting MouseMove events.
Solution:   Add the 'mousemoveevent' option with implementaiton for the GUI.
            (Ernie Rael, closes vim/vim#10044)
c4cb544cd5

This only ports the docs and the option variable.
The following commits will actually implement it as a UI option.
2022-09-04 21:18:08 +08:00
zeertzjq
900a774182
Merge pull request #20073 from zeertzjq/vim-088e8e344352
vim-patch:7.4.{1578,1624},088e8e344352
2022-09-04 20:41:01 +08:00
zeertzjq
21dad0dcf3 vim-patch:088e8e344352
Update runtime files.
088e8e3443

Also cherry-pick "partial" tag from a later runtime update.
2022-09-04 18:39:55 +08:00
zeertzjq
6f7d55d3d9 vim-patch:7.4.{1578,1624}
975b5271ee
03602ec28e
2022-09-04 18:39:55 +08:00
Christian Clason
24fbda04b9
build(deps): bump tree-sitter-c to v0.20.2 (#20079) 2022-09-04 12:09:04 +02:00
Gregory Anders
ea10e0c104
ci: remove gpanders from api reviewers (#20074) 2022-09-03 21:49:45 -06:00
Christian Clason
927d4d2a15
fix(filetype): run filetype.match on StdinReadPost (#20070)
Problem: filetype detection does not run on piped input
Solution: add `StdinReadPost` to main filetype.lua autocommand

Rationale: legacy filetype detection checked contents by sourcing
`scripts.vim` in separate autocommands, including on `StdinReadPost`.
For Lua filetype detection, this was moved into the main autocommand,
with bundled `scripts.vim` gated behind `g:do_legacy_filetype` (i.e.,
only user `scripts.vim` are sourced for compatibility by default). Adding
`StdinReadPost` to the main autocommand again runs content checks on
piped input without requiring code duplication and low-payoff
refactoring.
2022-09-03 19:27:57 +02:00
Stephan Seitz
c50460cf3b
feat(treesitter): include language in invalid query error (#14053) 2022-09-03 16:02:58 +02:00
dundargoc
ea611c7122
ci(clint): remove "Inner expression indentation should be 4" rule (#20047)
It completely breaks down in shada.c and is generally useless.
2022-09-03 12:00:00 +02:00
Christian Clason
5296e9407d
build(deps): bump tree-sitter to v0.20.7 (#20067) 2022-09-03 11:30:24 +02:00
Lewis Russell
1e3073bc35
docs: update .git-blame-ignore-revs (#20066) 2022-09-03 10:18:05 +01:00
zeertzjq
042d5df956
Merge pull request #20063 from zeertzjq/vim-9.0.0360
vim-patch:8.2.1505,9.0.{0360,0362}
2022-09-03 09:39:13 +08:00
zeertzjq
c62e5b5079 vim-patch:9.0.0362: expanding ":e %" does not work for remote files
Problem:    Expanding ":e %" does not work for remote files.
Solution:   If the "%" or "#" file does not exist add the expansion anyway.
f5724376ab
2022-09-03 09:01:09 +08:00
zeertzjq
7243b1cbde vim-patch:9.0.0360: crash when invalid line number on :for is ignored
Problem:    Crash when invalid line number on :for is ignored.
Solution:   Do not check breakpoint for non-existing line.
35d21c6830

Test does not fail without the fix in Nvim as Nvim uses 0 when line
number overflows. If it is changed to MAXLNUM then the test does fail
without the fix, but using 0 seems better as E481 is still given.
2022-09-03 09:01:09 +08:00
zeertzjq
05b49ef975 vim-patch:8.2.1505: not all file read and writecode is tested
Problem:    Not all file read and writecode is tested.
Solution:   Add a few tests. (Dominique Pellé, closes vim/vim#6764)
1b04ce2d40

Cherry-pick Test_glob() from patch 8.2.0634.
2022-09-03 09:01:08 +08:00
Lewis Russell
1ffd527c83
refactor: migrate comment style (#20012)
Done automatically using the following perl command:

  perl -pi -0777pe 's#\n\K */\*\n(.+?)\s*\*/\n#join("\n", map { $_ =~ s:^\s*\K \*://:; $_ } split("\n", $1)) . "\n"#sge' src/nvim/**/*.c

Co-authored-by: zeertzjq <zeertzjq@outlook.com>

Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2022-09-02 17:39:49 +01:00
bfredl
69456f3414
Merge pull request #20026 from dundargoc/refactor/char_u/7
refactor: replace char_u with char 7: remove `vim_strnsave`
2022-09-02 17:06:00 +02:00
zeertzjq
1ef7720567 fix(api)!: correctly deal with number before :tab
Now nvim_parse_cmd and nvim_create_user_command use a "tab" value which
is the same as the number passed before :tab modifier instead of the
number plus 1, and "tab" value is -1 if :tab modifier is not used.
2022-09-02 22:28:57 +08:00
Lewis Russell
2afcdbd63a
feat(Man): port to Lua (#19912)
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2022-09-02 15:20:29 +01:00
bfredl
e085d0be31
Merge pull request #20055 from famiu/fix/ui-attach/memory-leak
fix(ui): ui compositor does not correctly free event callbacks
2022-09-02 15:07:39 +02:00
Famiu Haque
2dd55f81f7 fix(ui): ui compositor does not correctly free event callbacks
Prior to this PR, when freeing event callbacks, UI compositor did not
free the luarefs which could cause potential memory leaks. This PR fixes
that by freeing the luarefs properly.
2022-09-02 17:49:51 +06:00
Jonas Strittmatter
ce80b8f50d
vim-patch:9.0.0349: filetype of *.sil files not well detected (#20050)
Problem:    Filetype of *.sil files not well detected.
Solution:   Inspect the file contents to guess the filetype.
be807d5824
2022-09-02 08:16:17 +02:00
zeertzjq
12fe197cff
Merge pull request #20040 from zeertzjq/vim-9.0.0342
vim-patch:9.0.{0342,0346}: :horizontal modifier
2022-09-01 21:31:38 +08:00
zeertzjq
689f5d604e feat(api): add support for :horizontal modifier 2022-09-01 20:53:43 +08:00
zeertzjq
56bf026dea vim-patch:9.0.0346: :horizontal modifier not fully supported
Problem:    :horizontal modifier not fully supported.
Solution:   Also use :horizontal for completion and user commands.
            (closes vim/vim#11025)
d3de178e53
2022-09-01 20:28:23 +08:00
zeertzjq
c65b1f3e15 vim-patch:9.0.0342: ":wincmd =" equalizes in two directions
Problem:    ":wincmd =" equalizes in two directions.
Solution:   Make ":vertical wincmd =" equalize vertically only and
            ":horizontal wincmd =" equalize horizontally only.
21c3a80a7f
2022-09-01 20:25:29 +08:00
Dundar Göc
49e893f296 refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
2022-09-01 10:47:42 +02:00
zeertzjq
db2e5f46f5
fix(lua): make ui_attach()/ui_detach() take effect immediately (#20037) 2022-09-01 16:37:29 +08:00
bfredl
48ca1d4ce8
Merge pull request #20022 from dundargoc/refactor/char_u/6
refactor: replace char_u with char 6
2022-09-01 10:25:27 +02:00
bfredl
d9a873f278
Merge pull request #20038 from bfredl/unflush
perf(messages): don't call ui_flush() per message line in various places
2022-09-01 10:18:14 +02:00
bfredl
5f92d9b345 perf(messages): don't call ui_flush() per message line in various places
When msgsep is used, message scrolling is emulated. To make message
output fast, inhibit emulated scrolling until the full message text
is known
2022-09-01 09:44:01 +02:00
bfredl
dd8489c399
Merge pull request #20023 from bfredl/hlarena
refactor(highlight): make hlattrs2dict always use pre-allocated dict
2022-09-01 09:22:31 +02:00
zeertzjq
a62cb406b1
fix(maparg): remove double allocation (#20033)
ASAN doesn't catch this, as it is referenced by the garbage collector.
Also remove a condition that is always true.
2022-09-01 10:22:28 +08:00
zeertzjq
8740e0bd58
vim-patch:9.0.0343: ColorScheme autocommand triggered when colorscheme not found (#20032)
Problem:    ColorScheme autocommand triggered when colorscheme is not found.
            (Romain Lafourcade)
Solution:   Only trigger ColorScheme when loading the colorscheme succeeds.
            (closes vim/vim#11024)
5d09a401ec

Most of Test_colorscheme() is applicable to Nvim.
2022-09-01 09:12:20 +08:00
zeertzjq
0c6b39894f
feat(mapset): support restoring Lua callback (#20024)
vim-patch:9.0.0341: mapset() does not restore <Nop> mapping properly

Problem:    mapset() does not restore <Nop> mapping properly.
Solution:   Use an empty string for <Nop>. (closes vim/vim#11022)
92a3d20682
2022-09-01 06:19:49 +08:00
bfredl
c0050b71e5
Merge pull request #16396 from bfredl/luaevent
feat(lua): vim.ui_attach to get ui events from lua
2022-08-31 22:03:56 +02:00
Dundar Göc
bd51ac2a34 refactor: replace char_u with char
Work on https://github.com/neovim/neovim/issues/459
2022-08-31 21:17:10 +02:00
bfredl
ba8be7446d refactor(highlight): make hlattrs2dict always use pre-allocated dict
hlattrs2dict used to work with both allocated and unallocated
dicts which was quite messy. Now always delegate allocation to caller.
2022-08-31 21:15:04 +02:00