Commit Graph

24588 Commits

Author SHA1 Message Date
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
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
zeertzjq
a0a1125159
Merge pull request #22002 from zeertzjq/vim-9.0.1227
vim-patch:9.0.{1227,1231,1238,1242}: cmdline completion for :runtime
2023-01-26 12:17:51 +08:00
zeertzjq
62f09017e0 test: add test for :runtime completion for .lua 2023-01-26 11:55:34 +08:00
zeertzjq
ebc80dcded vim-patch:9.0.1242: code for :runtime completion is not consistent
Problem:    Code for :runtime completion is not consistent.
Solution:   Make code for cmdline expansion more consistent. (closes vim/vim#11875)

b0d45ec67f
2023-01-26 11:55:34 +08:00
zeertzjq
f03f6263bb vim-patch:9.0.1238: :runtime completion can be further improved
Problem:    :runtime completion can be further improved.
Solution:   Also complete the {where} argument values and adjust the
            completion for that. (closes vim/vim#11874)

5c8771bc5a
2023-01-26 11:55:34 +08:00
zeertzjq
6320c91c50 vim-patch:9.0.1231: completion of :runtime does not handle {where} argument
Problem:    Completion of :runtime does not handle {where} argument.
Solution:   Parse the {where} argument. (closes vim/vim#11863)

3770f4c9cd
2023-01-26 11:55:34 +08:00
zeertzjq
6644786db0 vim-patch:9.0.1227: no cmdline completion for :runtime
Problem:    No cmdline completion for :runtime.
Solution:   Add completion for :runtime. (closes vim/vim#11853, closes vim/vim#11447)
            Improve the resulting matches.

a6759381a5
2023-01-26 11:55:32 +08:00
zeertzjq
5ac34cf55d
refactor(intro): avoid Coverity warning (#22000)
refactor(intro): avoid coverity warning

Problem:    Coverity warns about overwriting "mesg" leaking memory.
Solution:   Make it clear that "mesg" will not be overwritten.
2023-01-26 09:30:26 +08:00
zeertzjq
116766f243
refactor(options): don't pass negative number to illegal_char() (#21999)
This only changes the error messages for an unexpected Unicode char in
an option to show its first byte instead of some special keycode.

The second argument of vim_strchr() usually doesn't matter, but it may
be better to consistently cast to uint8_t.
2023-01-26 09:12:33 +08:00
zeertzjq
88e906d165
vim-patch:9.0.1245: code is indented more than necessary (#21998)
Problem:    Code is indented more than necessary.
Solution:   Use an early return where it makes sense. (Yegappan Lakshmanan,
            closes vim/vim#11879)

032713f829

Co-authored-by: Yegappan Lakshmanan <yegappan@yahoo.com>
2023-01-26 08:52:21 +08:00
zeertzjq
f15947866c
vim-patch:9.0.1243: :setglobal cannot use script-local function for "expr" option (#21997)
Problem:    :setglobal cannot use script-local function for "expr" option.
Solution:   Use the pointer to the option value properly. (closes vim/vim#11883)

01d4efe2e8
2023-01-26 07:46:51 +08:00
zeertzjq
c94d8e7f13
vim-patch:9.0.1244: cursor displayed in wrong position when leaving Insert mode (#21996)
Problem:    Cursor briefly displayed in a wrong position when pressing Esc in
            Insert mode after autoindent was used.
Solution:   Do not adjust the cursor position for assumed deleted white space
            if text is following.  (closes vim/vim#11877)

0f843ef091

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2023-01-26 07:31:32 +08:00
dundargoc
b05100a9ea
build: use cmake to build libvterm on all platform (#21986)
Also remove Libvterm-tbl2inc_c.cmake as it's not required. It's used to
generate files that are already provided by the Libvterm project by
default. It's also not really something we need to concern ourselves
with as it's more of an authoring tool for the Libvterm creator as
mentioned in
https://github.com/neovim/neovim/pull/21986#issuecomment-1403733054.
2023-01-26 00:06:52 +01:00
dundargoc
15394b6855
ci: fix lintc to use external dependencies instead of bundled (#21995)
Use the bundled libvterm dependency as the external package is outdated,
with the hopes of being able to use the external package once its
version meets our required version.

Co-authored-by: Christian Clason <c.clason@uni-graz.at>
2023-01-25 20:33:18 +01:00
0xAdk
3c48d3c83f
fix(man.lua): open in current window if it's already a man page (#21987)
This matters when there are multiple man page windows open.
2023-01-25 22:39:25 +08:00
Lewis Russell
e2a9d71521
Merge pull request #21885 from lewis6991/refactor/options
Problems:
    - Scope of local variables in options code is too large.
    - did_set_string_option() is too large (>1000LOC).
    - Setting options for a particular window or buffer requires a changing context (assigning curwin/curbuf).

Solutions:
    - Reduce the scope of local variables.
    - Break up did_set_string_option so it doesn't contain specific logic about each individual option (1038 LOC -> 310 LOC).
    - Begin work on making functions not depend on curbuf or curwin and pass window or buffer handles explicitly.
2023-01-25 13:46:23 +00:00
dundargoc
b8288df99b
build: introduce default build variables (#21991)
There are a number of cmake variables and cache variables that need to
be passed to all dependencies. This is not only cumbersome, but also
fragile as it's easy to miss adding or removing a flag from a dependency
by accident. Introducing a global variable that controls all builds
makes it much easier to handle our dependencies.

Also fixes the currently broken release workflow as we need to pass the
CMAKE_OSX_ARCHITECTURES variable to all dependencies built with cmake.
2023-01-25 14:36:17 +01:00
Lewis Russell
7bee622fdc refactor(optionstr.c): move handling of formatlistpat 2023-01-25 12:17:38 +00:00
Lewis Russell
15499fa856 refactor(optionstr.c): break up did_set_expropt 2023-01-25 12:13:06 +00:00
Lewis Russell
f37ec6026f refactor(optionstr.c): remove some redundant parens 2023-01-25 11:48:55 +00:00
Lewis Russell
b278e0740e refactor(optionstr.c): break up did_option_listflags 2023-01-25 11:48:55 +00:00
Lewis Russell
38ed432164 refactor(optionstr.c): add did_set_string_option_for 2023-01-25 11:48:55 +00:00
Lewis Russell
414e71fa4f refactor(optionstr.c): break up did_set_string_option 52 2023-01-25 11:48:53 +00:00
Lewis Russell
0012ed2bc7 refactor(optionstr.c): break up did_set_string_option 51 2023-01-25 11:48:53 +00:00
Lewis Russell
2654a9e9d8 refactor(optionstr.c): remove some simple did_set_* functions 2 2023-01-25 11:48:53 +00:00
Lewis Russell
e5234d48ed refactor(optionstr.c): remove some simple did_set_* functions 2023-01-25 11:48:53 +00:00
Lewis Russell
c6e7abb583 refactor(optionstr.c): break up did_set_string_option 50 2023-01-25 11:48:53 +00:00
Lewis Russell
6dac70bbfe refactor(optionstr.c): break up did_set_string_option 49 2023-01-25 11:48:53 +00:00
Lewis Russell
01e51d3bd1 refactor(optionstr.c): break up did_set_string_option 48 2023-01-25 11:48:53 +00:00
Lewis Russell
f1ac5aec23 refactor(optionstr.c): break up did_set_string_option 47 2023-01-25 11:48:53 +00:00
Lewis Russell
cb1e5ddbfb refactor(optionstr.c): break up did_set_string_option 46 2023-01-25 11:48:52 +00:00
Lewis Russell
e0954f676a refactor(optionstr.c): break up did_set_string_option 45 2023-01-25 11:48:52 +00:00
Lewis Russell
a026cf0d94 refactor(optionstr.c): break up did_set_string_option 44 2023-01-25 11:48:52 +00:00
Lewis Russell
d59349de7b refactor(optionstr.c): break up did_set_string_option 43 2023-01-25 11:48:52 +00:00
Lewis Russell
99910c7382 refactor(optionstr.c): break up did_set_string_option 42 2023-01-25 11:48:52 +00:00
Lewis Russell
2a83a5077d refactor(optionstr.c): break up did_set_string_option 41 2023-01-25 11:48:52 +00:00
Lewis Russell
a84bc3817a refactor(optionstr.c): break up did_set_string_option 40 2023-01-25 11:48:52 +00:00
Lewis Russell
902b89ad4b refactor(optionstr.c): break up did_set_string_option 39 2023-01-25 11:48:52 +00:00
Lewis Russell
4c365548a2 refactor(optionstr.c): break up did_set_string_option 38 2023-01-25 11:48:52 +00:00
Lewis Russell
3ea6a45a12 refactor(optionstr.c): break up did_set_string_option 37 2023-01-25 11:48:52 +00:00
Lewis Russell
bc2c9b1a08 refactor(optionstr.c): break up did_set_string_option 36 2023-01-25 11:48:52 +00:00
Lewis Russell
6d701cf772 refactor(optionstr.c): break up did_set_string_option 35 2023-01-25 11:48:52 +00:00
Lewis Russell
47544b6255 refactor(optionstr.c): break up did_set_string_option 34 2023-01-25 11:48:52 +00:00
Lewis Russell
b693d65171 refactor(optionstr.c): break up did_set_string_option 33 2023-01-25 11:48:52 +00:00