[gnome-builder] Revert "plugins: added GVls as Vala Language Server"
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] Revert "plugins: added GVls as Vala Language Server"
- Date: Sat, 14 Dec 2019 20:43:24 +0000 (UTC)
commit d425bfd7737854232eee11fffe5fbc0affe7864b
Author: Christian Hergert <chergert redhat com>
Date: Sat Dec 14 12:41:48 2019 -0800
Revert "plugins: added GVls as Vala Language Server"
This reverts commit c84f54f469678d713edde98a0dc60c7523276bc7.
src/plugins/gvls/gvls.plugin | 9 +++------
src/plugins/gvls/gvls_plugin.py | 26 +++++++++++++++++++++++---
src/plugins/gvls/meson.build | 4 ++--
src/plugins/meson.build | 1 -
4 files changed, 28 insertions(+), 12 deletions(-)
---
diff --git a/src/plugins/gvls/gvls.plugin b/src/plugins/gvls/gvls.plugin
index 6c890cd20..dc826e62c 100644
--- a/src/plugins/gvls/gvls.plugin
+++ b/src/plugins/gvls/gvls.plugin
@@ -1,12 +1,9 @@
# gvls.plugin
[Plugin]
-Author=Daniel Espinosa
Name=GNOME Vala Language Server for GNOME Builder plugin
-Description=GNOME Builder plugin for GVLS using LSP
+Module=gvls-plugin
+Author=Daniel Espinosa
+Description=GNOME Builder plugin for GVLS, without any LPS protocol support
Copyright=Copyright © 2019 Daniel Espinosa
-Builtin=true
-Loader=python3
-Module=gvls_plugin
-X-Builder-ABI=3.32
X-Completion-Provider-Languages=vala
diff --git a/src/plugins/gvls/gvls_plugin.py b/src/plugins/gvls/gvls_plugin.py
index 34dd70356..b95ded550 100644
--- a/src/plugins/gvls/gvls_plugin.py
+++ b/src/plugins/gvls/gvls_plugin.py
@@ -26,14 +26,13 @@ by bridging them to our supervised Vala Language Server.
import gi
import os
-import gvls_server
from gi.repository import GLib
from gi.repository import Gio
from gi.repository import GObject
from gi.repository import Ide
-DEV_MODE = True
+DEV_MODE = False
class GVlsService(Ide.Object):
_client = None
@@ -117,6 +116,7 @@ class GVlsService(Ide.Object):
# Setup a launcher to spawn the rust language server
launcher = self._create_launcher()
launcher.set_clear_env(False)
+ sysroot = self._discover_sysroot()
if DEV_MODE:
launcher.setenv('RUST_LOG', 'debug', True)
# Locate the directory of the project and run gvls from there.
@@ -124,7 +124,7 @@ class GVlsService(Ide.Object):
launcher.set_cwd(workdir.get_path())
# If org.gnome.gvls.stdio.Server is installed by GVls
- path_to_rls = gvls_server.gvls_stdio_server
+ path_to_rls = "org.gnome.gvls.stdio.Server"
# Setup our Argv. We want to communicate over STDIN/STDOUT,
# so it does not require any command line options.
@@ -198,4 +198,24 @@ class GVlsCompletionProvider(Ide.LspCompletionProvider):
# want the results. So use high priority (negative is better).
return -1000
+class GVlsRenameProvider(Ide.LspRenameProvider):
+ def do_load(self):
+ GVlsService.bind_client(self)
+
+class GVlsSymbolResolver(Ide.LspSymbolResolver):
+ def do_load(self):
+ GVlsService.bind_client(self)
+
+class GVlsHighlighter(Ide.LspHighlighter):
+ def do_load(self):
+ GVlsService.bind_client(self)
+
+class GVlsFormatter(Ide.LspFormatter):
+ def do_load(self):
+ GVlsService.bind_client(self)
+class GVlsHoverProvider(Ide.LspHoverProvider):
+ def do_prepare(self):
+ self.props.category = 'Vala'
+ self.props.priority = 200
+ GVlsService.bind_client(self)
diff --git a/src/plugins/gvls/meson.build b/src/plugins/gvls/meson.build
index 86295da69..248c8a39c 100644
--- a/src/plugins/gvls/meson.build
+++ b/src/plugins/gvls/meson.build
@@ -1,5 +1,7 @@
if get_option('plugin_gvls')
+#dependency('gvls-0.12')
+
install_data('gvls_plugin.py', install_dir: plugindir)
configure_file(
@@ -10,6 +12,4 @@ configure_file(
install_dir: plugindir,
)
-gvls_stdio_server = find_program('org.gnome.gvsl.stdio.Server')
-
endif
diff --git a/src/plugins/meson.build b/src/plugins/meson.build
index dd3dc631c..2c185658e 100644
--- a/src/plugins/meson.build
+++ b/src/plugins/meson.build
@@ -187,7 +187,6 @@ status += [
'Sysprof ............... : @0@'.format(get_option('plugin_sysprof')),
'Sysroot ............... : @0@'.format(get_option('plugin_sysroot')),
'Todo .................. : @0@'.format(get_option('plugin_todo')),
- 'Vala Language Server... : @0@'.format(get_option('plugin_gvls')),
'Vala Pack ............. : @0@'.format(get_option('plugin_vala')),
'Vagrant ............... : @0@'.format(get_option('plugin_vagrant')),
'Valgrind .............. : @0@'.format(get_option('plugin_valgrind')),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]