Commit Graph

1641 Commits

Author SHA1 Message Date
Gianmaria Bajo
ca887b80a9
fix: version-range < and <= #23539
vim.version.range() couldn't parse them correctly.
For example, vim.version.range('<0.9.0'):has('0.9.0') returned `true`.

fix: range:has() accepts vim.version()
So that it's possible to compare a range with:

    vim.version.range(spec):has(vim.version())
2023-06-06 06:38:45 -07:00
Gregory Anders
cbbda3bcd7
fix(editorconfig): check that buffer is valid (#23922)
Fixes: https://github.com/neovim/neovim/issues/23921
2023-06-05 11:53:13 -05:00
Gregory Anders
ca26ec3438
fix(lsp): use only utf-16 in default client positionEncodings (#23903)
The Nvim client does not yet support multiple offset encodings for
clients in the same buffer. Until it does, stick to utf-16 by default.
2023-06-05 08:21:23 -05:00
Jon Huhn
416fe8d185
refactor(lsp): use LPeg for watchfiles matching (#23788) 2023-06-05 07:19:31 +02:00
Raphael
3c6d971e54
fix(lsp): set extra info only when it has a value (#23868) 2023-06-05 07:17:38 +02:00
Folke Lemaitre
5282d3299c
fix(lsp): restore marks after apply_text_edits() #14630
PROBLEM:
Whenever any text edits are applied to the buffer, the `marks` part of those
lines will be lost. This is mostly problematic for code formatters that format
the whole buffer like `prettier`, `luafmt`, ...

When doing atomic changes inside a vim doc, vim keeps track of those changes and
can update the positions of marks accordingly, but in this case we have a whole
doc that changed. There's no simple way to update the positions of all marks
from the previous document state to the new document state.

SOLUTION:
* save marks right before `nvim_buf_set_lines` is called inside `apply_text_edits`
* check if any marks were lost after doing `nvim_buf_set_lines`
* restore those marks to the previous positions

TEST CASE:
* have a formatter enabled
* open any file
* create a couple of marks
* indent the whole file to the right
* save the file
Before this change: all marks will be removed.
After this change: they will be preserved.

Fixes #14307
2023-06-04 16:45:01 -07:00
Artyom Andreev
96e19533f6
feat(lsp): set kind in select call for codelens #23889 2023-06-03 18:03:25 -07:00
Christian Clason
0a439e3863
vim-patch:9.0.1601: filetype detection fails for *.conf file without comments (#23896)
Problem:    Filetype detection fails for *.conf file without comments.
            (Dmitrii Tcyganok)
Solution:   Use "conf" filetype as a fallback for an empty .conf file.
            (closes vim/vim#12487, closes vim/vim#12483)

664fd12aa2

Co-authored-by: zeertzjq <zeertzjq@outlook.com>
2023-06-04 00:39:46 +02:00
Lewis Russell
40db569014
perf(iter): make ListIter.totable more efficient (#23714) 2023-06-03 12:06:10 +02:00
Lewis Russell
2db719f6c2
feat(lua): rename vim.loop -> vim.uv (#22846) 2023-06-03 12:06:00 +02:00
Sebastian Lyng Johansen
c65e2203f7
docs(iter): add emmylua type to iter module (#23845) 2023-06-03 09:18:05 +02:00
dundargoc
aa130d0c7e
docs: small fixes (#23619)
Co-authored-by: Evgeni Chasnovski <evgeni.chasnovski@gmail.com>
Co-authored-by: Gustavo Ferreira <gustavo.ferreira@imaginecurve.com>
Co-authored-by: Kai Moschcau <mail@kmoschcau.de>
Co-authored-by: Lampros <hauahx@gmail.com>
2023-06-02 22:59:58 +08:00
zeertzjq
843c1bed95
fix(health): stop job properly on timeout (#23877) 2023-06-02 17:23:45 +08:00
Gregory Anders
15641f38cf feat(lsp): include positionEncodings in default client capabilities 2023-06-01 11:46:37 -05:00
Gregory Anders
fb54e6980e feat(lsp): set client offset_encoding if server supports positionEncoding
If the server sends the positionEncoding capability in its
initialization response, automatically set the client's offset_encoding
to use the value provided.
2023-06-01 11:34:23 -05:00
Raphael
be5e361154
fix(lsp): add param assert in client_is_stopped (#23857) 2023-06-01 08:38:38 +02:00
jdrouhard
58618d208a
feat(lsp)!: promote LspRequest to a full autocmd and enrich with additional data (#23694)
BREAKING CHANGE: LspRequest is no longer a User autocmd but is now a
first class citizen.

LspRequest as a User autocmd had limited functionality. Namely, the only
thing you could do was use the notification to do a lookup on all the
clients' requests tables to figure out what changed.

Promoting the autocmd to a full autocmd lets us set the buffer the
request was initiated on (so people can set buffer-local autocmds for
listening to these events).

Additionally, when used from Lua, we can pass additional metadata about
the request along with the notification, including the client ID, the
request ID, and the actual request object stored on the client's
requests table. Users can now listen for these events and act on them
proactively instead of polling all of the requests tables and looking
for changes.
2023-05-30 20:56:29 +02:00
Folke Lemaitre
dd3fa64573
fix(lsp): fix dynamic registration of code actions (#23826) 2023-05-30 19:15:07 +02:00
Omar El Halabi
e8776074f5
vim-patch:9.0.1591: some "gomod" files are not recognized (#23820)
Problem:    Some "gomod" files are not recognized.
Solution:   Check for "go.mod" file name before checking out the contents.
            (Omar El Halabi, closes vim/vim#12462)

c9fbd2560f
2023-05-30 06:44:23 +08:00
Christian Clason
b8a2220f5e
vim-patch:9.0.1587: Corn config files are not recognized (#23807)
Problem:    Corn config files are not recognized.
Solution:   Add a pattern for Corn config files. (Jake Stanger, closes vim/vim#12449)

05843e8960

Co-authored-by: Jake Stanger <mail@jstanger.dev>
2023-05-29 10:25:05 +02:00
Christian Clason
8e17054a23
vim-patch:9.0.1584: not all meson files are recognized (#23797)
Problem:    Not all meson files are recognized.
Solution:   Add "meson.options". (Liam Beguin, closes vim/vim#12444)

1ba0b9e36f

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2023-05-28 11:47:07 +02:00
Folke Lemaitre
ddd92a70d2
feat(lsp): initial support for dynamic capabilities (#23681)
- `client.dynamic_capabilities` is an object that tracks client register/unregister
- `client.supports_method` will additionally check if a dynamic capability supports the method, taking document filters into account. But only if the client enabled `dynamicRegistration` for the capability
- updated the default client capabilities to include dynamicRegistration for:
    - formatting
    - rangeFormatting
    - hover
    - codeAction
    - hover
    - rename
2023-05-28 07:51:28 +02:00
Matthieu Coudron
44d4ae448d
fix: function was renamed (#23772) 2023-05-26 21:51:18 +02:00
Lewis Russell
1fe1bb084d refactor(options): deprecate nvim[_buf|_win]_[gs]et_option
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Co-authored-by: famiu <famiuhaque@protonmail.com>
2023-05-21 15:14:01 +06:00
Christian Clason
e3e6fadfd8
feat(fs): expose join_paths as vim.fs.joinpath (#23685)
This is a small function but used a lot in some plugins.
2023-05-20 17:30:48 +02:00
Jon Huhn
073035a030
fix(lsp): don't register didChangeWatchedFiles when capability not set (#23689)
Some LSP servers (tailwindcss, rome) are known to request registration
for `workspace/didChangeWatchedFiles` even when the corresponding client
capability does not advertise support. This change adds an extra check
in the `client/registerCapability` handler not to start a watch unless
the client capability is set appropriately.
2023-05-20 07:45:39 +02:00
Christian Clason
201f366b37
vim-patch:9.0.1565: json lines files are not recognized (#23677)
Problem:    Json lines files are not recognized.
Solution:   Add a pattern to detect "jsonl" files. (issue vim/vim#7520)

6fadbc1e8c

Co-authored-by: Bram Moolenaar <Bram@vim.org>
2023-05-19 09:11:22 +02:00
Lewis Russell
ef64e225f6
fix(treesitter): allow foldexpr without highlights (#23672)
Ref nvim-treesitter/nvim-treesitter#4748
2023-05-18 10:52:01 +01:00
Lewis Russell
189fb62032
feat(treesitter): improved logging (#23638)
- Add bindings to Treesitter ts_parser_set_logger and ts_parser_logger
- Add logfile with path STDPATH('log')/treesitter.c
- Rework existing LanguageTree loggin to use logfile
- Begin implementing log levels for vim.g.__ts_debug
2023-05-17 11:42:18 +01:00
Lewis Russell
6b19170d44
fix(treesitter): correctly calculate bytes for text sources (#23655)
Fixes #20419
2023-05-16 16:41:47 +01:00
Christian Clason
9ff59517cb fix(treesitter): update c queries 2023-05-15 14:13:42 +02:00
dundargoc
08991b0782
docs: small fixes
Co-authored-by: Christian Clason <c.clason@uni-graz.at>
Co-authored-by: Gregory Anders <greg@gpanders.com>
Co-authored-by: HiPhish <hiphish@posteo.de>
Co-authored-by: Julio B <julio.bacel@gmail.com>
Co-authored-by: T727 <74924917+T-727@users.noreply.github.com>
Co-authored-by: camoz <camoz@users.noreply.github.com>
Co-authored-by: champignoom <66909116+champignoom@users.noreply.github.com>
2023-05-13 21:33:22 +02:00
Christian Clason
6f29c68928
vim-patch:9.0.1549: USD filetype is not recognized (#23608)
Problem:    USD filetype is not recognized.
Solution:   Add patterns for USD filetype. (Colin Kennedy, closes vim/vim#12370)

b848ce6b7e

Co-authored-by: Colin Kennedy <colinvfx@gmail.com>
2023-05-13 15:00:08 +02:00
Christian Clason
32dc484ec9
fix(treesitter): support subfiletypes in get_lang (#23605) 2023-05-13 13:29:11 +02:00
Raphael
512a90520e
refactor(lsp): mark server_ready function as deprecated (#23520) 2023-05-13 11:27:05 +02:00
Lewis Russell
af040c3a07
feat(treesitter): add support for setting query depths 2023-05-11 11:13:32 +01:00
Gaétan Lepage
e90b506903
vim-patch:9.0.1539: typst filetype is not recognized (#23578)
Problem:    Typst filetype is not recognized.
Solution:   Distinguish between sql and typst. (Gaetan Lepage, closes vim/vim#12363)

4ce1bda869
2023-05-11 15:43:02 +08:00
hituzi no sippo
4e5061dba7
docs(lsp): fix config.cmd argument for vim.lsp.start_client (#23560) 2023-05-09 21:00:29 +02:00
Jon Huhn
075a72d5ff
fix(lsp): fix relative patterns for workspace/didChangeWatchedFiles (#23548) 2023-05-09 18:12:54 +02:00
hituzi no sippo
02f92978fe
docs(lsp): fix type of config.cmd argument for vim.lsp.start_client (#23550) 2023-05-09 17:24:49 +02:00
Vadim A. Misbakh-Soloviov
209ed16f57
fix(man.lua): return support of all sections
Current behaviour of `:Man` is to only work with "number" sections.
This is caused by wrong assumptions about man sections naming.

Also, there was similar assumption about length of section dirs
in `paths` variable.

fixes #23485

Signed-off-by: Vadim Misbakh-Soloviov <git@mva.name>
2023-05-07 17:31:33 +07:00
marcoSven
9248dd77ac
feat(lua): add hl priority opts on yank (#23509)
feat(lua): add hl priority opts on_yank

Signed-off-by: marcoSven <me@marcosven.com>
2023-05-06 21:53:36 +02:00
jdrouhard
648f777931
perf(lsp): load buffer contents once when processing semantic tokens responses (#23484)
perf(lsp): load buffer contents once when processing semantic token responses

Using _get_line_byte_from_position() for each token's boundaries was a
pretty huge bottleneck, since that function would load individual buffer
lines via nvim_buf_get_lines() (plus a lot of extra overhead). So each
token caused two calls to nvim_buf_get_lines() (once for the start
position, and once for the end position).

For semantic tokens, we only attach to buffers that have already been
loaded, so we can safely just get all the lines for the entire buffer at
once, and lift the rest of the _get_line_byte_from_position()
implementation directly while bypassing the part that loads the buffer
line.

While I was looking at get_lines (used by _get_line_byte_from_position),
I noticed that we were checking for non-file URIs before we even looked
to see if we already had the buffer loaded. Moving the buffer-loaded
check to be the first thing done in get_lines() more than halved the
average time spent transforming the token list into highlight ranges vs
when it was still using _get_line_byte_from_position. I ended up
improving that loop more by not using get_lines, but figured the
performance improvement it provided was worth leaving in.
2023-05-05 07:41:36 +02:00
Bogdan Grigoruță
143a178332
fix(editorconfig): add missing root validation (#23462) 2023-05-03 12:26:40 -06:00
Lewis Russell
3ba930844c
perf(treesitter): insert/remove items efficiently (#23443) 2023-05-02 22:27:14 +01:00
Lewis Russell
fba18a3b62
fix(treesitter): do not calc folds on unloaded buffers
Fixes #23423
2023-05-02 10:07:18 +01:00
Lewis Russell
26cc946226
fix(treesitter): foldexpr tweaks
Some small general fixes found working on developing async parsing.
2023-05-01 10:32:29 +01:00
Christian Clason
37dd818722
vim-patch:9.0.1503: Luau files are not recognized (#23412)
Problem:    Luau files are not recognized.
Solution:   Add a patter for Luau files. (Amaan Qureshi, closes vim/vim#12317)

2dcfe9ae1d

Co-authored-by: Amaan Qureshi <amaanq12@gmail.com>
2023-05-01 10:55:51 +02:00
jdrouhard
edf05b005f
perf(lsp): process semantic tokens response in a coroutine that yields every 5ms (#23375) 2023-05-01 07:15:32 +02:00
Lewis Russell
19a793545f
fix(treesitter): redraw added/removed injections properly (#23287)
When injections are added or removed make sure to:
- invoke 'changedtree' callbacks for when new trees are added.
- invoke 'changedtree' callbacks for when trees are invalidated
- redraw regions when languagetree children are removed
2023-04-30 17:11:38 +02:00
Christian Clason
668f16bac7
feat(treesitter): upstream query omnifunc from playground (#23394)
and set by default in `ftplugin/query.lua`
2023-04-30 11:01:54 +02:00
Gregory Anders
2d54f5e903
Merge pull request #23382 from gpanders/iter-benchmark
Add vim.iter benchmark to benchmark test suite
2023-04-29 20:33:27 -06:00
Stephan Seitz
c194acbfc4
feat(treesitter): add query_linter from nvim-treesitter/playground (#22784)
Co-authored-by: clason <clason@users.noreply.github.com>
Co-authored-by: lewis6991 <lewis6991@users.noreply.github.com>
2023-04-29 18:22:26 +02:00
Gregory Anders
ef1801cc7c perf(iter): reduce number of table allocations
Packing and unpacking return values impairs performance considerably.
In an attempt to avoid creating tables as much as possible we can
instead pass return values between functions (which does not require
knowing the number of values a function might return). This makes the
code more complex, but improves benchmark numbers non-trivially.
2023-04-28 15:38:50 -06:00
bfredl
45bcf83869 refactor(build): include lpeg as a library 2023-04-27 11:40:00 +02:00
Gregory Anders
cacc2dc419
Merge pull request #23303 from gpanders/more-vim-iter
Create iter_spec and vim.iter module
2023-04-25 09:17:46 -06:00
ii14
7e70ca0b48
feat(lua): vim.keycode (#22960)
Using nvim_replace_termcodes is too verbose, add vim.keycode for
translating keycodes.

Co-authored-by: ii14 <ii14@users.noreply.github.com>
2023-04-25 16:52:44 +02:00
Gregory Anders
1e73891d69 refactor(iter): move helper functions under vim.iter
vim.iter is now both a function and a module (similar to vim.version).
2023-04-25 08:23:16 -06:00
Christian Clason
f17bb4f411
vim-patch:9.0.1478: filetypes for *.v files not detected properly (#23282)
* vim-patch:9.0.1478: filetypes for *.v files not detected properly

Problem:    Filetypes for *.v files not detected properly.
Solution:   Use the file contents to detect the filetype. (Turiiya,
            closes vim/vim#12281)

80406c2618

Co-authored-by: Turiiya <34311583+tobealive@users.noreply.github.com>
Co-authored-by: Jonas Strittmatter <40792180+smjonas@users.noreply.github.com>
2023-04-23 14:15:52 +02:00
zeertzjq
1cb46abff1
vim-patch:9.0.1475: busted configuration files are not recognized (#23266)
Problem:    Busted configuration files are not recognized.
Solution:   Recognize busted configuration files as Lua. (Craig MacEachern,
            closes vim/vim#12209)

Co-authored-by: C.D. MacEachern <craig.daniel.maceachern@gmail.com>
2023-04-22 23:51:53 +08:00
Jon Huhn
e9b85acfbb
feat(lsp): enable workspace/didChangeWatchedFiles by default (#23190) 2023-04-22 09:37:38 +02:00
Gregory Anders
f68af3c3bc
refactor(iter): use metatable as packed table tag (#23254)
This is a more robust method for tagging a packed table as it completely
eliminates the possibility of mistaking an actual table key as the
packed table tag.
2023-04-21 16:13:39 -06:00
Justin M. Keyes
824766612d refactor(lua): simplify vim.gsplit impl 2023-04-21 13:50:22 +02:00
Justin M. Keyes
622b1ae38a fix(lua): vim.split may trim inner empty items
Problem:
`vim.split('a:::', ':', {trimempty=true})` trims inner empty items.
Regression from 9c49c10470

Solution:
Set `empty_start=false` when first non-empty item is found.
close #23212
2023-04-21 13:50:22 +02:00
William
ab2811746e
fix(treesitter playground): fix the wrong range of a node displayed i… (#23209)
fix(treesitter playground): wrong range of a node displayed in playground

The call parameters order of the function `get_range_str` is flipped for the last two arguments compared to the declaration.
2023-04-20 07:42:49 -06:00
Gregory Anders
0ad5237162
Merge pull request #23198 from gpanders/iter-fix
fix(iter): allow table values in iterator pipelines
2023-04-19 08:23:42 -06:00
Gregory Anders
9489406879 fix(iter): remove special case totable for map-like tables
This was originally meant as a convenience but prevents possible
functionality. For example:

  -- Get the keys of the table with even values
  local t = { a = 1, b = 2, c = 3, d = 4 }
  vim.iter(t):map(function(k, v)
    if v % 2 == 0 then return k end
  end):totable()

The example above would not work, because the map() function returns
only a single value, and cannot be converted back into a table (there
are many such examples like this).

Instead, to convert an iterator into a map-like table, users can use
fold():

  vim.iter(t):fold({}, function(t, k, v)
    t[k] = v
    return t
  end)
2023-04-19 07:52:04 -06:00
Gregory Anders
6b96122453 fix(iter): add tag to packed table
If pack() is called with a single value, it does not create a table; it
simply returns the value it is passed. When unpack is called with a
table argument, it interprets that table as a list of values that were
packed together into a table.

This causes a problem when the single value being packed is _itself_ a
table. pack() will not place it into another table, but unpack() sees
the table argument and tries to unpack it.

To fix this, we add a simple "tag" to packed table values so that
unpack() only attempts to unpack tables that have this tag. Other tables
are left alone. The tag is simply the length of the table.
2023-04-19 07:04:49 -06:00
Christian Clason
cff02e993d
vim-patch:9.0.1467: Jenkinsfiles are not recognized as groovy (#23195)
Problem:    Jenkinsfiles are not recognized as groovy.
Solution:   Add a pattern for Jenkinsfiles. (closes vim/vim#12236)

142ffb024d

Co-authored-by: dundargoc <gocdundar@gmail.com>
2023-04-19 10:19:33 +02:00
Christian Clason
6d9f5b6bf0
vim-patch:9.0.1464: strace filetype detection is expensive (#23175)
Problem:    Strace filetype detection is expensive.
Solution:   Match with a cheap pattern first. (Federico Mengozzi,
            closes vim/vim#12220)

6e5a9f9482

Co-authored-by: Federico Mengozzi <19249682+fedemengo@users.noreply.github.com>
2023-04-19 09:41:26 +02:00
Gregory Anders
ab1edecfb7
feat(lua): add vim.iter (#23029)
vim.iter wraps a table or iterator function into an `Iter` object with
methods such as `filter`, `map`, and `fold` which can be chained to
produce iterator pipelines that do not create new tables at each step.
2023-04-17 12:54:19 -06:00
Jon Huhn
6cc76011ca
fix(watchfiles): skip Created events when poll starts (#23139) 2023-04-17 18:50:05 +02:00
Isak Samsten
07b60efd80
feat(diagnostic): specify diagnostic virtual text prefix as a function
- vim.diagnostic.config() now accepts a function for the virtual_text.prefix
  option, which allows for rendering e.g., diagnostic severities differently.
2023-04-17 12:53:34 +01:00
JingMatrix
7f94a032e1
fix(checkhealth): shell_error and cpanm module
shell_error is a function, the code missed parentheses

The actual module for perl module version is App::cpanminus::script, not
App::cpanminus::fatscript.
2023-04-16 12:39:48 +02:00
dundargoc
b0978fca6b
fix(checkhealth): fix crash due to incorrect argument type 2023-04-16 12:26:13 +02:00
Raphael
2f779b94e7
fix(lua): inspect_pos respect bufnr when get syntax info (#23098) 2023-04-16 17:50:32 +08:00
Christian Clason
d9e9dc3a06
vim-patch:9.0.1455: C++ 20 modules are not recognized (#23124)
Problem:    C++ 20 modules are not recognized.
Solution:   Add patterns to recognize C++ 20 modules as "cpp". (Ben Jackson,
            closes vim/vim#12261)

732d69e191

Co-authored-by: Ben Jackson <puremourning@gmail.com>
2023-04-16 10:59:04 +02:00
dundargoc
c08b030761
refactor: deprecate checkhealth functions
The following functions are deprecated and will be removed in
Nvim v0.11:

- health#report_start()
- health#report_info()
- health#report_ok()
- health#report_warn()
- health#report_error()
- vim.health.report_start()
- vim.health.report_info()
- vim.health.report_ok()
- vim.health.report_warn()
- vim.health.report_error()

Users should instead use these:

- vim.health.start()
- vim.health.info()
- vim.health.ok()
- vim.health.warn()
- vim.health.error()
2023-04-15 23:40:48 +02:00
zeertzjq
8c6f97bef8
fix(health): properly use the value of $PYENV_VERSION (#23109) 2023-04-16 00:16:50 +08:00
NAKAI Tsuyoshi
7caf0eafd8
feat(lua)!: add stricter vim.tbl_islist() and rename old one to vim.tbl_isarray() (#16440)
feat(lua)!: add stricter vim.tbl_islist(), rename vim.tbl_isarray()

Problem: `vim.tbl_islist` allows gaps in tables with integer keys
("arrays").

Solution: Rename `vim.tbl_islist` to `vim.tbl_isarray`, add new
`vim.tbl.islist` that checks for consecutive integer keys that start
from 1.
2023-04-14 12:01:08 +02:00
Christian Clason
4d04feb662
feat(lua): vim.tbl_contains supports general tables and predicates (#23040)
* feat(lua): vim.tbl_contains supports general tables and predicates

Problem: `vim.tbl_contains` only works for list-like tables (integer
keys without gaps) and primitive values (in particular, not for nested
tables).

Solution: Rename `vim.tbl_contains` to `vim.list_contains` and add new
`vim.tbl_contains` that works for general tables and optionally allows
`value` to be a predicate function that is checked for every key.
2023-04-14 10:39:57 +02:00
Gregory Anders
bfb28b62da
refactor: remove modelines from Lua files
Now that we have builtin EditorConfig support and a formatting check in
CI, these are not necessary.
2023-04-13 23:29:13 +02:00
Lewis Russell
66c66d8db8
fix(loader): reset hashes when running the loader 2023-04-13 17:34:47 +01:00
Mathias Fußenegger
37011bc45e
fix(diagnostic): rename buffer → bufnr in type annotation (#23042)
See `:h diagnostic-structure`, the property name is `bufnr`, not
`buffer`.
2023-04-12 15:16:15 +02:00
NAKAI Tsuyoshi
9e86f473e0
feat(lua): vim.region accepts getpos() arg (#22635) 2023-04-11 16:28:46 +02:00
Scott Ming
ccc0980f86
fix(treesitter): Use the correct replacement args for #gsub! directive (#23015)
fix(treesitter): use the correct replacement args for #gsub! directive
2023-04-11 10:26:03 +02:00
zeertzjq
7ffe450173
fix(health): check for _host_prog variables properly (#23014) 2023-04-11 10:20:25 +08:00
zeertzjq
c8d1d8b254
fix(man.lua): don't continue on command error (#23009)
Fix #21169
2023-04-11 09:35:01 +08:00
Gregory Anders
03a021f378
fix(health): combine python and virtualenv healthchecks (#23004)
fix(health): combine python and virtualenv health checks
2023-04-10 15:46:22 -06:00
Gregory Anders
cde4892b49
fix(health): fix typo in function name 2023-04-10 22:37:25 +02:00
dundargoc
bd98ef6ac6
refactor: rewrite perl healthcheck in lua
This is required to remove the vimscript checkhealth functions.
2023-04-10 15:59:50 +02:00
dundargoc
b5c0e7137c
refactor: rewrite node healthcheck in lua
This is required to remove the vimscript checkhealth functions.
2023-04-10 15:26:22 +02:00
dundargoc
7801ffc38a
refactor: rewrite ruby healthcheck in lua
This is required to remove the vimscript checkhealth functions.
2023-04-10 14:06:10 +02:00
dundargoc
5ed7ede1f5
refactor: rewrite virtualenv healthcheck in lua
This is required to remove the vimscript checkhealth functions.
2023-04-10 11:28:42 +02:00
dundargoc
71225228fc
refactor: rewrite python provider healthcheck in Lua
This is required to remove the vimscript checkhealth functions.
2023-04-09 22:28:00 +02:00
dundargoc
41b7586cbb
refactor: rewrite clipboard provider healthchecks in Lua
This is required to remove the vimscript checkhealth functions.
2023-04-09 20:46:53 +02:00
Gregory Anders
d675bd01b1
feat(lua): allow vim.F.if_nil to take multiple arguments (#22903)
The first argument which is non-nil is returned. This is useful when
using nested default values (e.g. in the EditorConfig plugin).

Before:

  local enable = vim.F.if_nil(vim.b.editorconfig, vim.F.if_nil(vim.g.editorconfig, true))

After:

  local enable = vim.F.if_nil(vim.b.editorconfig, vim.g.editorconfig, true)
2023-04-07 08:22:47 -06:00
Lewis Russell
e29bc03c04
fix(treesitter): do not track ranges of the root tree (#22912)
Fixes #22911
2023-04-06 15:16:44 +01:00
Lewis Russell
34ac75b329
refactor: rename local API alias from a to api
Problem:
  Codebase inconsistently binds vim.api onto a or api.

Solution:
  Use api everywhere. a as an identifier is too short to have at the
  module level.
2023-04-05 17:19:53 +01:00
Michal Liszcz
999cb36c2b
refactor(lsp): do not parse verbose output when overwriting options (#22810) 2023-04-05 14:02:08 +02:00