Modules/Neovim: Rewrite clangd root_dir expression for neovim v0.11
This commit is contained in:
@ -842,21 +842,15 @@ in {
|
|||||||
{
|
{
|
||||||
name = "clangd";
|
name = "clangd";
|
||||||
extraOptions = {
|
extraOptions = {
|
||||||
root_dir.__raw = ''
|
root_markers = [
|
||||||
function(fname)
|
"Makefile"
|
||||||
-- return require("lspconfig.util").root_pattern(
|
"CMakeLists.txt"
|
||||||
return vim.lsp.config.util.root_pattern(
|
".clang-format"
|
||||||
"Makefile",
|
".clang-tidy"
|
||||||
"CMakeLists.txt",
|
"compile_commands.json"
|
||||||
".clang-format",
|
];
|
||||||
".clang-tidy"
|
|
||||||
-- )(fname) or require("lspconfig.util").root_pattern(
|
workspace_required = true;
|
||||||
)(fname) or vim.lsp.config.util.root_pattern(
|
|
||||||
"compile_commands.json"
|
|
||||||
-- )(fname) or require("lspconfig.util").find_git_ancestor(fname)
|
|
||||||
)(fname) or vim.lsp.config.util.find_git_ancestor(fname)
|
|
||||||
end
|
|
||||||
'';
|
|
||||||
|
|
||||||
cmd = [
|
cmd = [
|
||||||
"clangd"
|
"clangd"
|
||||||
|
|||||||
Reference in New Issue
Block a user