aboutsummaryrefslogtreecommitdiffstats
path: root/lua/lspconfig/solargraph.lua
diff options
context:
space:
mode:
Diffstat (limited to 'lua/lspconfig/solargraph.lua')
-rw-r--r--lua/lspconfig/solargraph.lua32
1 files changed, 32 insertions, 0 deletions
diff --git a/lua/lspconfig/solargraph.lua b/lua/lspconfig/solargraph.lua
new file mode 100644
index 00000000..5aa2ec17
--- /dev/null
+++ b/lua/lspconfig/solargraph.lua
@@ -0,0 +1,32 @@
+local configs = require 'lspconfig/configs'
+local util = require 'lspconfig/util'
+
+local bin_name = "solargraph"
+if vim.fn.has('win32') == 1 then
+ bin_name = bin_name..'.bat'
+end
+configs.solargraph = {
+ default_config = {
+ cmd = {bin_name, "stdio"};
+ filetypes = {"ruby"};
+ root_dir = util.root_pattern("Gemfile", ".git");
+ };
+ docs = {
+ package_json = "https://raw.githubusercontent.com/castwide/vscode-solargraph/master/package.json";
+ description = [[
+https://solargraph.org/
+
+solargraph, a language server for Ruby
+
+You can install solargraph via gem install.
+
+```sh
+gem install solargraph
+```
+ ]];
+ default_config = {
+ root_dir = [[root_pattern("Gemfile", ".git")]];
+ };
+ };
+};
+-- vim:et ts=2 sw=2