Commit Graph

24699 Commits

Author SHA1 Message Date
dundargoc
533bdcb25e
build: remove unnecessary file generation (#22099)
paths.lua.in doesn't rely on any generator expressions, so it's safe to
remove file(GENERATE).
2023-02-02 12:27:48 +01:00
luukvbaal
64fa75a86a
fix(column): estimate 'statuscolumn' width appropriately
Problem:    The 'statuscolumn' width is being estimated without the
            proper context. In particular, this resulted in the fact
            that a custom fold column could be included in the estimated
            `number_width()`, and doubly added when actually drawing the
            statuscolumn due to `win_col_off()` also adding the
            `'foldcolumn'` width. Resulting in a status column that is
            `'foldcolumn'` cells wider than necessary.
Solution:   Estimate 'statuscolumn' width in `get_statuscol_str()` when
            a buffer's line count has changed.
2023-02-02 09:35:51 +00:00
Thayne McCombs
cb97d5425a docs: clarify "pipe" mode for sockconnect
Make it more clear that on unix the "pipe" mode of sockconnect uses unix
local domain sockets, not named pipes (FIFOs) which are not currently
supported.

See discussion in #22080.

Signed-off-by: Thayne McCombs
2023-02-02 01:00:17 -07:00
zeertzjq
2c5906b55b
fix(exit): skip unnecessary steps in TUI preserve_exit() (#21897)
This prevents the TUI from doing unexpected things when receiving a
deadly signal or running out of memory.
2023-02-02 10:05:03 +08:00
github-actions[bot]
ecc1595c7b
version.c: update [skip ci] (#21306)
Co-authored-by: marvim <marvim@users.noreply.github.com>

N/A patches:
vim-patch:9.0.1272: typo in pattern for filetype detection
2023-02-02 08:07:11 +08:00
zeertzjq
fa35d3c33a
vim-patch:9.0.1273: "1v" may select block with wrong size (#22092)
Problem:    "1v" may select block with wrong size. (Evgeni Chasnovski)
Solution:   Compute "curswant" in the right line. (closes vim/vim#11925)

8f531662e2

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2023-02-02 08:05:15 +08:00
Lewis Russell
9ce44a750c
fix(man): use italics for <bs>_ (#22086)
fix(man): use italics for <bs>_

Even though underline is strictly what this should be. <bs>_ was used by
nroff to indicate italics which wasn't possible on old typewriters so
underline was used. Modern terminals now support italics so lets use
that now.

See:
- https://unix.stackexchange.com/questions/274658/purpose-of-ascii-text-with-overstriking-file-format/274795#274795
- https://cmd.inp.nsk.su/old/cmd2/manuals/unix/UNIX_Unleashed/ch08.htm
2023-02-01 17:21:42 +00:00
zeertzjq
4cc0d6b854
vim-patch:9.0.1271: using sizeof() and subtract array size is tricky (#22087)
Problem:    Using sizeof() and subtract array size is tricky.
Solution:   Use offsetof() instead. (closes vim/vim#11926)

1b438a8228
2023-02-01 21:53:32 +08:00
Christian Clason
a26c0ecab6
Merge pull request #22082 from clason/bump-vimdoc
build(deps): bump tree-sitter-vimdoc to v1.3.0
2023-02-01 12:08:54 +01:00
Christian Clason
37da48cabd build(deps): bump tree-sitter-vimdoc to v1.3.0 2023-02-01 11:34:51 +01:00
zeertzjq
01d3a64e28
vim-patch:8.1.1827: allocating more memory than needed for extended structs (#22081)
Problem:    Allocating more memory than needed for extended structs.
Solution:   Use offsetof() instead of sizeof(). (Dominique Pelle,
            closes vim/vim#4786)

47ed553fd5
2023-02-01 18:07:09 +08:00
Christian Clason
d63ad600e0
vim-patch:9.0.1268: .clangd and .stylelintrc files don't get a filetype (#22079)
Problem:    .clangd and .stylelintrc files don't get a filetype.
Solution:   Use yaml for .clangd and json for .stylelintrc files. (Mark
            Skelton, closes vim/vim#11916)

9c51798a1f

Co-authored-by: Mark Skelton <mdskelton99@gmail.com>
2023-02-01 10:08:50 +01:00
zeertzjq
7880eeb2ee
vim-patch:9.0.1270: crash when using search stat in narrow screen (#22078)
Problem:    Crash when using search stat in narrow screen.
Solution:   Check length of message. (closes vim/vim#11921)

a7d36b7320
2023-02-01 08:21:32 +08:00
zeertzjq
249b9de405
refactor(optionstr.c): align comments (#22070)
Align comments in did_set_string_option_for() at column 57.
2023-02-01 08:17:18 +08:00
bfredl
8376486e8f
Merge pull request #17537 from bfredl/neolua
refactor(tests): run unittests using main nvim binary - delete separate nvim-test build
2023-01-31 19:58:33 +01:00
bfredl
13aa23b62a refactor(tests): run unittests using main nvim binary in interpreter mode
This allows us to get rid of the separate "nvim-test" target
2023-01-31 19:28:26 +01:00
bfredl
42999a8d64 fix(test): fix issues detected by running unittests in ASAN/UBSAN 2023-01-31 18:28:29 +01:00
Christian Clason
8b11cf5092
Merge pull request #22005 from clason/sanitize-lang
fix(treesitter): validate language name
2023-01-31 17:28:32 +01:00
bfredl
d6d6ab3f8e feat(lua): low-level interpreter mode (nvim -ll) 2023-01-31 13:53:22 +01:00
bfredl
facbb11e05
Merge pull request #22068 from bfredl/lsptest
fix(tests): use -l mode for lsp tests
2023-01-31 13:49:51 +01:00
bfredl
50b256d515 fix(tests): use -l mode for lsp tests
This fixes "fake server" from leaking memory, which makes ASAN very
upset, except on current ASAN CI for some reason.
2023-01-31 13:15:23 +01:00
Christian Clason
b649a96fc0
vim-patch:9.0.1263: KDL files are not recognized (#22058)
Problem:    KDL files are not recognized.
Solution:   Add a pattern for KDL files. (Amaan Qureshi, closes vim/vim#11898)

907349a743

Co-authored-by: Amaan Qureshi <amaanq12@gmail.com>
2023-01-31 08:12:10 +01:00
zeertzjq
860fea1a3f
fix(highlight): properly deal with underline mask when listing (#22057) 2023-01-31 07:08:23 +08:00
dundargoc
27b81af19c
refactor!: remove has("debug") (#22060)
This value can not be relied on as it doesn't work for
multi-configuration generators. I don't think this undocumented option
is used much, if at all, so I think we should remove it.
2023-01-30 19:06:32 +01:00
dundargoc
979b7b0c49
build: add uninstall make target (#22059)
We already have a "make install", it makes sense to also have a "make
uninstall".
2023-01-30 18:45:07 +01:00
zeertzjq
21257d8580
build(luarocks): update busted version to v2.1.1 (#22029) 2023-01-30 17:01:06 +08:00
zeertzjq
3ac55fe083
build(bump_deps.lua): run command -v in shell (#22030)
When I run ./scripts/bump_deps.lua I get an error:

  Vim:E475: Invalid value for argument cmd: 'command' is not executable

Running command -v in shell fixes this.
2023-01-30 07:15:38 +08:00
Amaan Qureshi
c9ac4e4877
vim-patch:9.0.1261: Elsa files are not recognized (#22047)
Problem: Elsa files are not recognized.
Solution: Add the name of Elsa files. (Amaan Qureshi)

2a99fe6c41
2023-01-29 20:19:07 +01:00
dundargoc
9cb3b276bd
ci(news): mention that ignoring news.txt is fine (#22043)
news.txt is only meant as a reminder, but contributors have no way of
knowing this automatically without such a message.
2023-01-29 17:03:53 +01:00
dundargoc
930125647f
build: enable ccache project-wide (#22045)
Currently, only the nvim target uses ccache but not libnvim or
unittests. It is generally a good idea to operate on targets rather than
globally, but this is an exception as there isn't a target where we
don't want to use ccache on.
2023-01-29 17:02:34 +01:00
Christian Clason
8144deb098
vim-patch:9.0.1256: NetworkManager connection files are not recognized (#22038)
Problem:    NetworkManager connection files are not recognized.
Solution:   Add a pattern for NetworkManager connection files. (closes vim/vim#11893)

04e4f1d985

Co-authored-by: ObserverOfTime <chronobserver@disroot.org>
2023-01-29 10:39:20 +01:00
zeertzjq
4c90a84c61
vim-patch:9.0.1255: changing 'virtualedit' does not have immediate effect (#22039)
Problem:    Changing 'virtualedit' does not have immediate effect.
Solution:   Correct how is checked for a changed value. (closes vim/vim#11878)

8fe5b9c8c1

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2023-01-29 07:42:22 +08:00
Christian Clason
c032e83b22 fix(treesitter): validate language name
Problem: Some injections (like markdown) allow specifying arbitrary
language names for code blocks, which may be lead to errors when
looking for a corresponding parser in runtime path.

Solution: Validate that the language name only contains alphanumeric
characters and `_` (e.g., for `c_sharp`) and error otherwise.
2023-01-28 11:28:52 +01:00
zeertzjq
b4c4c232ba
fix(fileio.c): don't use uninitialized memory (#22031) 2023-01-28 13:06:45 +08:00
dundargoc
881d4adb59
build: enable ccache by default if available (#22020)
Initial benchmarks show that this gives a nice 50% compile time
reduction for neovim. This shouldn't affect users or CI, but it's a nice
speedup for local development. The C_COMPILER_LAUNCHER target property
is only supported by Makefiles and Ninja generators only, so this won't
give a speedup when using the Xcode and Visual Studio generators even if
ccache is available.
2023-01-28 00:42:13 +01:00
Christian Clason
2cde6a18b5
build(deps): bump unibilium to d72c3598e7ac5d1ebf86ee268b8b4ed95c0fa628 (#22019)
actually use build system improvements
2023-01-27 14:53:53 +01:00
dundargoc
38365fa2ef
build: fix dependencies in find modules (#22017)
Find modules should only link to libraries defined in the find module,
and not the main project. This helps the find modules be more self-contained and easier to understand.
2023-01-27 14:16:31 +01:00
Lewis Russell
aec4b476c5
docs(api): tweak data arg for nvim_create_autocmd (#22008)
Fixes #21964
2023-01-27 11:24:20 +00:00
Lewis Russell
82fb6ce487
Merge pull request #21994 from lewis6991/refactor/option_set 2023-01-27 11:23:44 +00:00
dundargoc
d85ed00a8c
build: find unibilium without relying on libfindmacros (#22015)
This will remove the warning about the find module not providing a
version.
2023-01-27 11:53:32 +01:00
Lewis Russell
77a0ce1d9b refactor(option.c): factor out string option special case handling 2023-01-27 10:43:42 +00:00
Lewis Russell
068151f5c6 refactor(option.c): factor out some nextchar checks 2023-01-27 10:43:41 +00:00
Lewis Russell
9b43dcdbff
fix(test): unset XDG_CONFIG_HOME when running oldtest
- also fix test_taglist.vim for users running with a tags file created
  in runtime/doc
2023-01-27 09:48:00 +00:00
dundargoc
843c9025ae
build: check if libvterm version meets requirement (#22010)
The vterm.h file only specifies major and minor version, but not patch,
meaning that requiring a specific patch number isn't currently possible.
2023-01-26 21:35:06 +01:00
Lewis Russell
3c2bb1b2be
refactor(fileio.c): reduce scope of locals 2023-01-26 15:17:23 +00:00
zeertzjq
41aa5ce3eb
vim-patch:9.0.1246: code is indented more than necessary (#22006)
Problem:    Code is indented more than necessary.
Solution:   Use an early return where it makes sense. (Yegappan Lakshmanan,
            closes vim/vim#11887)

142ed77898

Omit function_using_block_scopes(): only affects Vim9 script.

Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-01-26 21:05:34 +08:00
zeertzjq
e02df23b4e
docs: clarify :runtime behavior without [where] again (#22003)
The behavior changed again after #15867, change the docs to describe
latest behavior.
2023-01-26 19:35:06 +08:00
Anton Kriese
3544082f46
test: exepath() returns correct path with cmd.exe, powershell #21928
test(exepath): test if exepath returns correct path with multiple
Windows shells

This test covers the changes from #21175 where exepath() is set to
prefer file extensions in powershell.exe aswell as in cmd.exe.

In both shells, the file with a valid extension should be returned
instead of the extensionless file.
2023-01-26 03:06:29 -08:00
Lewis Russell
8f2d3537b4 refactor(option.c): add do_set_option_value 2023-01-26 10:42:26 +00:00
Lewis Russell
0170219e92 refactor(option.c): move bool prefix check 2023-01-26 10:26:07 +00:00