Problem: Some jsonc files are not recognized.
Solution: Add patterns for jsonc and move some from json to jsonc.
(closesvim/vim#11711)
104b2ff4d0
Co-authored-by: kylo252 <59826753+kylo252@users.noreply.github.com>
The BufWipeout autocmd is not 100% reliable and may leave stale entries
in the cache. This is sort of a hack/workaround to ensure
`vim.diagnostic.reset` calls don't fail if there are stale cache entries
but instead clears them
Fixes errors like
Error executing vim.schedule lua callback: /usr/share/nvim/runtime/lua/vim/diagnostic.lua:1458: Invalid buffer id: 22
stack traceback:
[C]: in function 'nvim_exec_autocmds'
/usr/share/nvim/runtime/lua/vim/diagnostic.lua:1458: in function 'reset'
While `return` and `return nil` are for most intents and purposes
identical, there are situations where they're not. For example,
calculating the amount of values via the `select()` function will yield
varying results:
```lua
local function nothing() return end
local function null() return nil end
select('#', nothing()) -- 0
select('#', null()) -- 1
```
`vim.tbl_get` currently returns both nil and no results, which makes it
unreliable to use in certain situations without manually accounting for
these discrepancies.
Problem: Conflict between supercollider and scala filetype detection.
Solution: Do not check for "Class : Method", it can appear in both
filetypes. (Chris Kipp, closesvim/vim#11699)
70ef3f546b
Co-authored-by: Chris Kipp <ckipp@pm.me>
Apply semantic token modifiers as separate extmarks with corresponding
highlight groups (e.g., `@readonly`). This is a low-effort PR to enable
the most common use cases (applying, e.g., italics or backgrounds on top
of type highlights; language-specific fallbacks like `@global.lua` are
also available). This can be replaced by more complicated selector-style
themes later on.
Instead of testing for every possible modifier type, only test bits up
to the highest set in the token array. Saves many bit ops and
comparisons when there are no modifiers or when the highest set bit is a
lower bit than the highest possible in the legend on average.
Can be further simplified when non-luaJIT gets the full bit module (see #21222)
The spec indicates that the response may be `null`, but it doesn't
really say what a `null` response means. Since neovim raises an error if
the response is `null`, I figured that ignoring it would be the safest
bet.
Co-authored-by: Mathias Fussenegger <f.mathias@zignar.net>
1. The algorithm for applying edits was slightly incorrect. It needs to
preserve the original token list as the edits are applied instead of
mutating it as it iterates. From the spec:
Semantic token edits behave conceptually like text edits on
documents: if an edit description consists of n edits all n edits are
based on the same state Sm of the number array. They will move the
number array from state Sm to Sm+1.
2. Schedule the semantic token engine start() call in the
client._on_attach() function so that users who schedule_wrap() their
config.on_attach() functions (like nvim-lspconfig does) can still
disable semantic tokens by deleting the semanticTokensProvider from
their server capabilities.
* credit to @smolck and @theHamsta for their contributions in laying the
groundwork for this feature and for their work on some of the helper
utility functions and tests
Add a "show_tree" function to view a textual representation of the
nodes in a language tree in a window. Moving the cursor in the
window highlights the corresponding text in the source buffer, and
moving the cursor in the source buffer highlights the corresponding
nodes in the window.
`willSaveWaitUntil` allows servers to respond with text edits before
saving a document. That is used by some language servers to format a
document or apply quick fixes like removing unused imports.
Problem: Zir files are not recognized.
Solution: Add a pattern for Zir files. (closesvim/vim#11664)
25201016d5
Co-authored-by: Bram Moolenaar <Bram@vim.org>
- use pcall when calling vim.secure.read from C
- catch keyboard interrupts in vim.secure.read, rethrow other errors
- selecting "view" in prompt runs :view command
- simplify lua stack cleanup with lua_gettop and lua_settop
Co-authored-by: ii14 <ii14@users.noreply.github.com>
Introduce vim.secure.trust() to programmatically manage the trust
database. Use this function in a new :trust ex command which can
be used as a simple frontend.
Resolves: https://github.com/neovim/neovim/issues/21092
Co-authored-by: Gregory Anders <greg@gpanders.com>
Co-authored-by: ii14 <ii14@users.noreply.github.com>
Problem: Eclipse preference files are not recognized.
Solution: Add a pattern to use "jproperties" for Eclipse preference files.
(closesvim/vim#11618)
f3f198b634
Co-authored-by: ObserverOfTime <chronobserver@disroot.org>
* vim-patch:9.0.0935: when using dash it may not be recognize as filetype "sh"
Problem: When using dash it may not be recognize as filetype "sh".
Solution: Add checks for "dash". (Eisuke Kawashima,closes vim/vim#11600)
24482fbfd5
Co-authored-by: Eisuke Kawashima <e-kwsm@users.noreply.github.com>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Problem: Oblivion files are not recognized.
Solution: Recognize Oblivion files and alike as "obse". (closesvim/vim#11540)
ecfd511e8d
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Problem: Workflow Description Language files are not recognized.
Solution: Add a pattern for the "wdl" filetype. (Matt Dunford,
closesvim/vim#11611)
f60bdc3417
Co-authored-by: Matt Dunford <zenmatic@gmail.com>
Some functions didn't include the `nil` case in the return type
annotation. This corrects those and also adds a Diagnostic class
definition for the diagnostic.get return type
This introduces a `suffix` option to the `virt_text` config in
`vim.diagnostic.config()`. The suffix can either be a string which is appended
to the diagnostic message or a function returning such. The function receives a
`diagnostic` argument, which is the diagnostic table of the last diagnostic (the
one whose message is rendered as virt text).
Closes#18687
This introduces a `suffix` option to `vim.diagnostic.open_float()` (and
consequently `vim.diagnostic.config()`) that appends some text to each
diagnostic in the float.
It accepts the same types as `prefix`. For multiline diagnostics, the suffix is
only appended to the last line. By default, the suffix will render the
diagnostic error code, if any.
Language servers can take some time to respond to the
`textDocument/hover` and `textDocument/signatureHelp` messages. During
that time, the user could have already moved to another buffer. The
popup was always shown in the current buffer, which could be a different
one than the buffer for which the request was sent.
This was particularly annoying when moving to a buffer with a `BufLeave`
autocmd, as that autocmd was triggered when the hover popup was shown
for the original buffer.
Ignoring the response from these 2 messages if they are for a buffer
that is not the current one leads to less noise. The popup will only be
shown for the buffer for which it was requested.
A more robust solution could involve cancelling the hover/signatureHelp
request if the buffer changes so the language server can free its
resources. It could be implemented in the future.
Problem: Clinical Quality Language files are not recognized.
Solution: Add the "*.cql" pattern. (Matthew Gramigna, closesvim/vim#11452)
12babe45a3
Co-authored-by: mgramigna <mgramigna@mitre.org>
This function accepts a path to a file and prompts the user if the file
is trusted. If the user confirms that the file is trusted, the contents
of the file are returned. The user's decision is stored in a trust
database at $XDG_STATE_HOME/nvim/trust. When this function is invoked
with a path that is already marked as trusted in the trust database, the
user is not prompted for a response.
Followup to #20883
Related: #18144
This patch changes the behavior of the default `vim.ui.input` when the user
aborts with `<C-c>`. Currently, it produces an error message + stack and causes
`on_confirm` to not be called. With this patch, `<C-c>` will cause `on_confirm`
to be called with `nil`, the same behavior as when the user aborts with `<Esc>`.
I can think of three good reasons why the behavior should be this way:
1. Easier for the user to understand** It's not intuitive for there to be two
ways to abort an input dialog that have _different_ outcomes. As a user,
I would expect any action that cancels the input to leave me in the same
state. As a plugin author, I see no value in having two possible outcomes for
aborting the input. I have to handle both cases, but I can't think of
a situation where I would want to treat one differently than the other.
2. Provides an API that can be overridden by other implementations** The current
contract of "throw an error upon `<C-c>`" cannot be replicated by async
implementations of `vim.ui.input`. If the callsite wants to handle the case
of the user hitting `<C-c>` they need to use `pcall(vim.ui.input, ...)`,
however an async implementation will instantly return and so there will be no
way for it to produce the same error-throwing behavior when the user inputs
`<C-c>`. This makes it impossible to be fully API-compatible with the
built-in `vim.ui.input`.
3. Provides a useful guarantee to the callsite** As a plugin author, I want the
guarantee that `on_confirm` will _always_ be called (only catastrophic errors
should prevent this). If I am in the middle of some async thread of logic,
I need some way to resume that logic after handing off control to
`vim.ui.input`. The only way to handle the `<C-c>` case is with `pcall`,
which as already mentioned, breaks down if you're using an alternative
implementation.
- If Nvim was just started, don't create a new tab.
- Name the buffer "health://".
- Use "help" syntax instead of "markdown". It fits better, and
eliminates various workarounds.
- Simplfy formatting, avoid visual noise.
- Don't print a "INFO" status, it is noisy.
- Drop the ":" after statuses, they are already UPPERCASE and highlighted.
Previously man.lua would use the `env` field in the parameters of
`vim.loop.spawn` to override things like MANPAGER. This caused issues on
NixOS since `spawn` will _override_ the environment rather than _append_
to it (and NixOS relies on a heavily modified environment). Using the
`env` command to append to the environment solves this issue.
fix(vim.ui.input): return empty string when inputs nothing
The previous behavior of `vim.ui.input()` when typing <CR> with
no text input (with an intention of having the empty string as input)
was to execute `on_confirm(nil)`, conflicting with its documentation.
Inputting an empty string should now correctly execute `on_confirm('')`.
This should be clearly distinguished from cancelling or aborting the
input UI, in which case `on_confirm(nil)` is executed as before.
Problem: VHS tape files are not recognized.
Solution: Add a filetype pattern. (Carlos Alexandro Becker, closesvim/vim#11452)
1756f4b218
Co-authored-by: Carlos A Becker <caarlos0@users.noreply.github.com>
Problem:
- pesc() returns multiple results, it should return a single result.
- tbl_islist() returns non-boolean in some branches.
- Docstring: @generic must be declared first
Solution:
Constrain docstring annotations.
Fix return types.
Co-authored-by: Justin M. Keyes <justinkz@gmail.com>
vim-patch:436e5d395fd6 (since upstream tagged the wrong commit)
Problem: Aws config files are not recognized.
Solution: Use "confini" for aws config files. (Justin M. Keyes,
closesvim/vim#11416)
436e5d395f
Problem: `*.db` files use empty string as default filetype, which is
inconsistent with the rest of the code which uses `nil` instead.
Solution: don't pass a default empty string
Problem: Clang format configuration files are not recognized.
Solution: Use yaml for Clang format configuration files. (Marwin Glaser,
closesvim/vim#11398)
3c708c4390
* fix(man): handle absolute paths as :Man targets
Previously, attempting to provide `:Man` with an absolute path as the name would
cause neovim to return the following error:
```
Error detected while processing command line:
/usr/local/share/nvim/runtime/lua/man.lua:690: /usr/local/share/nvim/runtime/lua/man.lua:683: Vim:E426: tag not found: nil(nil)
Press ENTER or type command to continue
```
..because it would try to validate the existence of a man page for the provided
name by executing `man -w /some/path` which (on at least some Linux machines
[0]) returns `/some/path` instead of the path to the nroff files that would be
formatted to satisfy the man(1) lookup.
While man pages are not normally named after absolute paths, users shouldn't be
blamed for trying. Given such a name/path, neovim would **not** complain that
the path didn't have a corresponding man file but would error out when trying
to call the tag function for the null-propagated name-and-section `nil(nil)`.
(The same underlying error existed before this function was ported to lua, but
did not exhibit the lua-specific `nil(nil)` name; instead a tag lookup for `()`
would fail and error out.)
With this patch, we detect the case where `man -w ...` returns the same value as
the provided name to not only prevent invoking the tag function for a
non-existent/malformed name+sect but also to properly report the non-existence
of a man page for the provided lookup (the absolute path).
While man(1) can be used to directly read an nroff-formatted document via `man
/path/to/nroff.doc`, `:Man /path/to/nroff.doc` never supported this behavior so
no functionality is lost in case the provided path _was_ an nroff file.
[0]: `man -w /absolute/path` returning `/absolute/path` observed on an Ubuntu
18.04 installation.
* test: add regression test for #20624
Add a functional test to `man_spec.lua` to check for a regression for #20624 by
first obtaining an absolute path to a random file and materializing it to disk,
then attempting to query `:Man` for an entry by that same name/path.
The test passes if nvim correctly reports that there is no man page
correspending to the provided name/path and fails if any other error (or no
error) is shown.
Made obsolete by now graduated `filetype.lua` (enabled by default).
Note that changes or additions to the filetype detection still need to
be made through a PR to vim/vim as we port the _logic_ as well as tests.
vim-patch:9.0.0771: cannot always tell the difference beween tex and rexx files
Problem: Cannot always tell the difference beween tex and rexx files.
Solution: Recognize tex by a leading backslash. (Martin Tournoij,
closesvim/vim#11380)
bd053f894b
Problem:
LSP client provides bogus capabilities in CodeActionKind.
LSP logs show this in the "initialize" message:
codeActionKind = { valueSet = { "Empty", "QuickFix",
"Refactor", "RefactorExtract", "RefactorInline", "RefactorRewrite",
"Source", "SourceOrganizeImports", "", "quickfix", "refactor",
"refactor.extract", "refactor.inline", "refactor.rewrite", "source",
"source.organizeImports" }
Solution:
Only the values from the CodeActionKind table should be presented, not also the
keys.
fix#20657
MacOS 13 has changed its version of `man` to an version that doesn't
properly support `man -w` (without arguments). In order to workaround
this we simply fallback to $MANPATH.
Fixes#20579
- 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).
Problem: HSL playlist files are not recognized.
Solution: Add a pattern to recognize HSL palylist files. (Benoît Ryder,
closesvim/vim#11204)
35fdd9a67d
When it happens it wastes 2 seconds which is NOT included in the
normal busted timing info. It is hard to correct this, but we
can at least print a warning when this happens.
vim-patch:9.0.0479: in :def function all closures in loop get the same variables
Problem: In a :def function all closures in a loop get the same variables.
Solution: Use a separate list of variables for LOADOUTER and SAVEOUTER.
1aea184a0d
(note: patch description is wrong)
fix(treesitter): get_captures_at_position returns metadata
Return the full `metadata` table for the capture instead of just the
priority.
Further cleanup of related docs.
Makes it possible to use `vim.fs.find` to find files where only a
substring is known.
This is useful for `vim.lsp.start` to get the `root_dir` for languages
where the project-file is only known by its extension, not by the full
name.
For example in .NET projects there is usually a `<projectname>.csproj`
file in the project root.
Example:
vim.fs.find(function(x) return vim.endswith(x, '.csproj') end, { upward = true })
The execution of the LspDetach autocommands in the LSP client's on_exit
function are scheduled on the event loop to avoid making API calls in a
fast context; however, this means that by the time the LspDetach
autocommands finally run the client object has already been deleted.
To address this, we also schedule the deletion of the client on the
event loop so that it is guaranteed to occur after all of the LspDetach
autocommands have fired.
Problem: Jsonnet files are not recognized.
Solution: Add a pattern for Jsonnet files. (Cezary Drożak, closesvim/vim#11073,
closesvim/vim#11081)
2a4c885d54
Use the first, not last, query for a language on runtimepath. Typically,
this implies that a user query will override a site plugin query, which
will override a bundled runtime query.
Problem: Treesitter queries for a given language in runtime were merged together,
leading to errors if they targeted different parser versions (e.g., bundled viml queries
and those shipped by nvim-treesitter).
Solution: Runtime queries now work as follows:
* The last query in the rtp without `; extends` in the header will be used as the base query
* All queries (without a specific order) with `; extends` are concatenated with the base query
BREAKING CHANGE: queries need to be updated if they are meant to extend other queries
Doing so on `BufDelete` has issues:
- `BufDelete` is also fired for listed buffers that are made unlisted.
- `BufDelete` is not fired for unlisted buffers that are deleted.
This means that diagnostics will be lost for a buffer that becomes unlisted.
It also means that if an entry exists for an unlisted buffer, deleting that
buffer later will not remove its entry from the cache (and you may see "Invalid
buffer id" errors when using diagnostic functions if it was wiped).
Instead, remove a buffer from the cache if it is wiped out.
This means simply `:bd`ing a buffer will not clear its diagnostics now.
- Added 'spell' option to extmarks:
Extmarks with this set will have the region spellchecked.
- Added 'noplainbuffer' option to 'spelloptions':
This is used to tell Neovim not to spellcheck the buffer. The old
behaviour was to spell check the whole buffer unless :syntax was set.
- Added spelling support to the treesitter highlighter:
@spell captures in highlights.scm are used to define regions which
should be spell checked.
- Added support for navigating spell errors for extmarks:
Works for both ephemeral and static extmarks
- Added '_on_spell_nav' callback for decoration providers:
Since ephemeral callbacks are only drawn for the visible screen,
providers must implement this callback to instruct Neovim which
regions in the buffer need can be spell checked.
The callback takes a start position and an end position.
Note: this callback is subject to change hence the _ prefix.
- Added spell captures for built-in support languages
Co-authored-by: Lewis Russell <lewis6991@gmail.com>
Co-authored-by: Björn Linse <bjorn.linse@gmail.com>
* Add vim.treesitter.start() for starting treesitter highlighting via
ftplugin or autocommand (can be extended later for fold, indent,
matchpairs, ...)
* Add vim.treesitter.stop() for manually stopping treesitter
highlighting
* Enable treesitter highlighting for Lua if
`vim.g.ts_highlight_lua = true` is set in `init.lua`
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.
* vim-patch:9.0.0314: VDM files are not recognized
Problem: VDM files are not recognized.
Solution: Add patterns for VDM files. (Alessandro Pezzoni, closesvim/vim#11004)
bf26941f40
* vim-patch:9.0.0319: Godot shader files are not recognized
Problem: Godot shader files are not recognized.
Solution: Add patterns for "gdshader". (Maxim Kim, closesvim/vim#11006)
d5c8f11905
This removes the support for defining links via
vim.treesitter.highlighter.hl_map (never documented, but plugins did
anyway), or the uppercase-only `@FooGroup.Bar` to `FooGroup` rule.
The fallback is now strictly `@foo.bar.lang` to `@foo.bar` to `@foo`,
and casing is irrelevant (as it already was outside of treesitter)
For compatibility, define default links to builting syntax groups
as defined by pre-existing color schemes
The private 'get_node_range' function from the languagetree module has
been renamed and remains private as it serve a purpose that is only
relevant inside the languagetree module.
The 'get_node_range' upstreamed from nvim-treesitter in the treesitter
module has been made public as it is in itself a utlity function.
As part of the upstream of utility functions from nvim-treesitter, this
option when set to false allows to return a table (downstream behavior).
Effectively making the switch from the downstream to the upstream
function much easier.
fix(filetype): only pass first 100 and last lines to contents check
sufficient for current content checks and avoids performance issues for
buffers with a large number of lines
fixes#19817
This starts a soft phase-out of `buf_request`.
`buf_request` is quite error prone:
- Positional `params` depend on the client because of the
`offset_encoding`. Currently if there is one client using UTF-8 offset
encoding and another using UTF-16, the positions in the request are
wrong for one of the clients. To solve this the params would need to
be created per client instead of once for all of them.
- `handler` is called *per* client but many users of it assume it is
only called once.
This can lead to a "select n + 1"
kind of problem, where the handler makes another call to `buf_request`,
multiplying the amount of requests.
(There are in fact still some places where this happens in core)
Or it leads to erratic behavior if called multiple times (E.g. the
quicklist list flickering & being overwritten)
(See hover or references implementation)
`buf_request_all` returns an aggregate of the responses which is more
sensible as it avoids this problem.
For off-spec extensions it also has the problem that it sends requests to
clients which cannot handle a given request.
Given that `buf_request` is in use by a lot of plugins this starts a
soft-phase out. Planned Steps:
- Remove from docs
- Provide an alternative, either `buf_request_all`, maybe with
extensions (params being a function), or an entirely new method.
- Mark as deprecated in 0.9
- Remove in 0.10
To note:
- `buf_request_all` currently isn't ideal either because it suffers from
the `params` problem as well.
- This implies that the `vim.lsp.with` pattern will die, because the
global handlers as they are don't fit a multi-client model, as most of
the time an aggregate is needed.
`server_capabilities` can be nil until the server is initialized.
Reproduced with:
vim.lsp.stop_client(vim.lsp.start_client {
cmd = { vim.v.progpath, '-es', '-u', 'NONE', '--headless' };
})
The change tracking used a single lines/lines_tmp table to track
changes to a buffer.
If multiple clients using incremental sync are connected to a buffer,
they both made changes to the same lines table. That resulted in an
inconsistent state.
This commit changes the didChange handling to group clients by
synchronization scheme and offset encoding.
This avoids computing the diff multiple times for clients using the
same scheme and resolves the lines/lines_tmp conflicts.
Fixes https://github.com/neovim/neovim/issues/19325
based on http://www.vim.org/scripts/script.php?script_id=1291
reformatted to match Nvim documentation style; removed irrelevant sections
Co-authored-by: dundargoc <gocundar@gmail.com>
Co-authored-by: Christian Clason <c.clason@uni-graz.at>
Co-authored-by: Lewis Russell <lewis6991@gmail.com>
The lsp client used to wait up to 500ms for a language server to
shutdown before sending a TERM signal.
The intention behind the 500ms grace period was to ensure the language
server exits to prevent stale processes, but it has the side-effect that
it can interrupt language-servers which are too slow to shutdown within
500ms. Language servers tend to write out index files or project files
on shutdown, and being interrupted during this process can cause
corruption of those files.
This changes the default to not wait at all, at the risk of leaving
stale processes around if the language server isn't well behaved.
An alternative would be to wait indefinitely, but that can cause neovim
to take several seconds to exit.
`:saveas newName` changes the name of an existing buffer.
Due to the buffer re-use it skips the lsp attach phase and immediately
sends a `didSave` notification to the server.
Servers get confused about this, because they expect a `didOpen`
notification first.
Closes https://github.com/neovim/neovim/issues/18688
`code_action` gained extra functions (`filter` and `apply`) which
`range_code_action` didn't have.
To close this gap, this adds a `range` option to `code_action` and
deprecates `range_code_action`.
The option defaults to the current selection if in visual mode.
This allows users to setup a mapping like `vim.keymap.set({'v', 'n'},
'<a-CR>', vim.lsp.buf.code_action)`
`range_code_action` used to use the `<` and `>` markers to get the
_last_ selection which required using a `<Esc><Cmd>lua
vim.lsp.buf.range_code_action()<CR>` (note the `<ESC>`) mapping.
Without some form of feedback a user cannot easily tell if the server is
still computing the result (which can take a while in large projects),
or whether the server couldn't compute the rename result.
Problem: Using "terraform" filetype for .tfvars file is bad.
Solution: use "terraform-vars", so that different completion and other
mechanisms can be used. (Radek Simko, closesvim/vim#10755)
15b87b6610
Currently LSP allows only using loclist or quickfix list window. I
normally prefer to review all quickfix items without opening quickfix
window. This fix allows passing `on_list` option which allows full
control what to do with list.
Here is example how to use it with quick fix list:
```lua
local function on_list(options)
vim.fn.setqflist({}, ' ', options)
vim.api.nvim_command('cfirst')
end
local bufopts = { noremap=true, silent=true, buffer=bufnr }
vim.keymap.set('n', '<leader>ad', function() vim.lsp.buf.declaration{on_list=on_list} end, bufopts)
vim.keymap.set('n', '<leader>d', function() vim.lsp.buf.definition{on_list=on_list} end, bufopts)
vim.keymap.set('n', '<leader>ai', function() vim.lsp.buf.implementation{on_list=on_list} end, bufopts)
vim.keymap.set('n', '<leader>at', function() vim.lsp.buf.type_definition{on_list=on_list} end, bufopts)
vim.keymap.set('n', '<leader>af', function() vim.lsp.buf.references(nil, {on_list=on_list}) end, bufopts)
```
If you prefer loclist do something like this:
```lua
local function on_list(options)
vim.fn.setloclist(0, {}, ' ', options)
vim.api.nvim_command('lopen')
end
```
close#19182
Co-authored-by: Mathias Fußenegger <mfussenegger@users.noreply.github.com>
* Problem
Quotes are special in doxygen, and should be escaped. *Sometimes* they
cause doc generation issues. Like in #17785
* Solution
Replace double quotes with single quotes
vim-patch:9.0.0055: bitbake files are not detected
Problem: Bitbake files are not detected.
Solution: Add bitbake filetype detection by file name and contents. (Gregory
Anders, closesvim/vim#10697)
fa49eb4827
Problem:
Since right-click can now show a popup menu, we can provide messaging to
guide users who expect 'mouse' to be disabled by default. So 'mouse' can
now be enabled by default.
Solution:
Do it.
Closes#15521
vim.lsp.start_client() may fail (for example if the `cmd` is not
executable). It produces a nice error notification in this case. Passing
the `nil` value returned from an erroneous `vim.lsp.start_client()` call
into `vim.lsp.buf_attach_client()` causes a meaty param validate
exception message. Avoid this.
Issuing a server request triggers `changetracking.flush` so as to
make sure we're not operating on a stale state. This immediately
triggers notification of any pending changes (as a result of debouncing)
to the server. However, this happens in addition to the notification
that is waiting on the debounce delay. Because we `nil`
`buf_state.pending_change` when it is called, the fix is to
also check that this is non-`nil` when it is called and exit if it is,
as this being `nil` would mean that it originates from a pending change
that has already been flushed out.
* revert to filetype.vim by setting `g:do_legacy_filetype`
* skip either filetype.lua or filetype.vim via `g:did_load_filetypes`
(Running both is no longer required and therefore no longer supported.)