[gnome-builder/wip/chergert/lsp-plugin-loader] plugins/clangd: port to generic LSP plugin
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder/wip/chergert/lsp-plugin-loader] plugins/clangd: port to generic LSP plugin
- Date: Fri, 14 Oct 2022 17:03:38 +0000 (UTC)
commit d7f61dc844687badd41f131dc48ce2306b9d5cd4
Author: Christian Hergert <chergert redhat com>
Date: Fri Oct 14 11:22:57 2022 -0500
plugins/clangd: port to generic LSP plugin
src/plugins/clangd/clangd-plugin.c | 70 ----------------------
src/plugins/clangd/clangd.gresource.xml | 1 +
src/plugins/clangd/clangd.plugin | 21 ++++---
.../clangd/gbp-clangd-code-action-provider.c | 65 --------------------
.../clangd/gbp-clangd-code-action-provider.h | 31 ----------
.../clangd/gbp-clangd-completion-provider.c | 61 -------------------
.../clangd/gbp-clangd-completion-provider.h | 31 ----------
.../clangd/gbp-clangd-diagnostic-provider.c | 65 --------------------
.../clangd/gbp-clangd-diagnostic-provider.h | 31 ----------
src/plugins/clangd/gbp-clangd-formatter.c | 65 --------------------
src/plugins/clangd/gbp-clangd-formatter.h | 31 ----------
src/plugins/clangd/gbp-clangd-highlighter.c | 65 --------------------
src/plugins/clangd/gbp-clangd-highlighter.h | 31 ----------
src/plugins/clangd/gbp-clangd-hover-provider.c | 66 --------------------
src/plugins/clangd/gbp-clangd-hover-provider.h | 31 ----------
src/plugins/clangd/gbp-clangd-rename-provider.c | 65 --------------------
src/plugins/clangd/gbp-clangd-rename-provider.h | 31 ----------
src/plugins/clangd/gbp-clangd-service.c | 59 ------------------
src/plugins/clangd/gbp-clangd-service.h | 31 ----------
src/plugins/clangd/gbp-clangd-symbol-resolver.c | 65 --------------------
src/plugins/clangd/gbp-clangd-symbol-resolver.h | 31 ----------
src/plugins/clangd/meson.build | 13 ----
src/plugins/clangd/settings.json | 4 ++
23 files changed, 17 insertions(+), 947 deletions(-)
---
diff --git a/src/plugins/clangd/clangd.gresource.xml b/src/plugins/clangd/clangd.gresource.xml
index f968fa838..680ebea14 100644
--- a/src/plugins/clangd/clangd.gresource.xml
+++ b/src/plugins/clangd/clangd.gresource.xml
@@ -2,5 +2,6 @@
<gresources>
<gresource prefix="/plugins/clangd">
<file>clangd.plugin</file>
+ <file>settings.json</file>
</gresource>
</gresources>
diff --git a/src/plugins/clangd/clangd.plugin b/src/plugins/clangd/clangd.plugin
index bb2569806..fff5051b5 100644
--- a/src/plugins/clangd/clangd.plugin
+++ b/src/plugins/clangd/clangd.plugin
@@ -2,17 +2,20 @@
Builtin=true
Copyright=Copyright © 2022 Christian Hergert
Description=Integration with clangd
-Embedded=_gbp_clangd_register_types
+Embedded=ide_lsp_plugin_register_types
Module=clangd
Name=Clangd Language Server
X-Category=lsps
-X-Code-Action-Languages=c,chdr,cpp,cpphdr,objc
-X-Completion-Provider-Languages=c,chdr,cpp,cpphdr,objc
-X-Diagnostic-Provider-Languages=c,chdr,cpp,cpphdr,objc
+X-Code-Action-Languages=c;chdr;cpp;cpphdr;objc
+X-Completion-Provider-Languages=c;chdr;cpp;cpphdr;objc
X-Diagnostic-Provider-Languages-Priority=200
-X-Formatter-Languages=c,chdr,cpp,cpphdr,objc
-X-Highlighter-Languages=c,chdr,cpp,cpphdr,objc
-X-Hover-Provider-Languages=c,chdr,cpp,cpphdr,objc
-X-Rename-Provider-Languages=c,chdr,cpp,cpphdr,objc
-X-Symbol-Resolver-Languages=c,chdr,cpp,cpphdr,objc
+X-Diagnostic-Provider-Languages=c;chdr;cpp;cpphdr;objc
+X-Formatter-Languages=c;chdr;cpp;cpphdr;objc
+X-Highlighter-Languages=c;chdr;cpp;cpphdr;objc
+X-Hover-Provider-Languages=c;chdr;cpp;cpphdr;objc
+X-LSP-Command=clangd
+X-LSP-Languages=c;cpp;objective-c;objective-cpp
+X-LSP-Settings=settings.json
+X-Rename-Provider-Languages=c;chdr;cpp;cpphdr;objc
X-Symbol-Resolver-Languages-Priority=200
+X-Symbol-Resolver-Languages=c;chdr;cpp;cpphdr;objc
diff --git a/src/plugins/clangd/meson.build b/src/plugins/clangd/meson.build
index d60f5b1fa..4179432c5 100644
--- a/src/plugins/clangd/meson.build
+++ b/src/plugins/clangd/meson.build
@@ -1,18 +1,5 @@
if get_option('plugin_clangd')
-plugins_sources += files([
- 'clangd-plugin.c',
- 'gbp-clangd-code-action-provider.c',
- 'gbp-clangd-completion-provider.c',
- 'gbp-clangd-diagnostic-provider.c',
- 'gbp-clangd-formatter.c',
- 'gbp-clangd-highlighter.c',
- 'gbp-clangd-hover-provider.c',
- 'gbp-clangd-rename-provider.c',
- 'gbp-clangd-symbol-resolver.c',
- 'gbp-clangd-service.c',
-])
-
plugin_clangd_resources = gnome.compile_resources(
'clangd-resources',
'clangd.gresource.xml',
diff --git a/src/plugins/clangd/settings.json b/src/plugins/clangd/settings.json
new file mode 100644
index 000000000..f23b598cd
--- /dev/null
+++ b/src/plugins/clangd/settings.json
@@ -0,0 +1,4 @@
+{
+ "clangd" : {
+ }
+}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]