From 0274356c5f3f913e866de390c43e02ed0b32de00 Mon Sep 17 00:00:00 2001 From: Johan Date: Sat, 31 Aug 2024 00:04:28 +0200 Subject: fix(bazelrc-lsp): rename bazelrc-lsp to bazelrc_lsp (#3287) Using bazelrc-lsp as the name makes it harder to import the module in Lua as it requires the dash to be escaped. This commit renames the lsp to bazelrc_lsp instead. --- .../server_configurations/bazelrc-lsp.lua | 26 ---------------------- .../server_configurations/bazelrc_lsp.lua | 26 ++++++++++++++++++++++ 2 files changed, 26 insertions(+), 26 deletions(-) delete mode 100644 lua/lspconfig/server_configurations/bazelrc-lsp.lua create mode 100644 lua/lspconfig/server_configurations/bazelrc_lsp.lua (limited to 'lua') diff --git a/lua/lspconfig/server_configurations/bazelrc-lsp.lua b/lua/lspconfig/server_configurations/bazelrc-lsp.lua deleted file mode 100644 index d89462a2..00000000 --- a/lua/lspconfig/server_configurations/bazelrc-lsp.lua +++ /dev/null @@ -1,26 +0,0 @@ -local util = require 'lspconfig/util' - -return { - default_config = { - cmd = { 'bazelrc-lsp' }, - filetypes = { 'bazelrc' }, - root_dir = util.root_pattern('WORKSPACE', 'WORKSPACE.bazel', 'MODULE.bazel'), - }, - docs = { - description = [[ -https://github.com/salesforce-misc/bazelrc-lsp - -`bazelrc-lsp` is a LSP for `.bazelrc` configuration files. - -The `.bazelrc` file type is not detected automatically, you can register it manually (see below) or override the filetypes: - -```lua -vim.filetype.add { - pattern = { - ['.*.bazelrc'] = 'bazelrc', - }, -} -``` -]], - }, -} diff --git a/lua/lspconfig/server_configurations/bazelrc_lsp.lua b/lua/lspconfig/server_configurations/bazelrc_lsp.lua new file mode 100644 index 00000000..d89462a2 --- /dev/null +++ b/lua/lspconfig/server_configurations/bazelrc_lsp.lua @@ -0,0 +1,26 @@ +local util = require 'lspconfig/util' + +return { + default_config = { + cmd = { 'bazelrc-lsp' }, + filetypes = { 'bazelrc' }, + root_dir = util.root_pattern('WORKSPACE', 'WORKSPACE.bazel', 'MODULE.bazel'), + }, + docs = { + description = [[ +https://github.com/salesforce-misc/bazelrc-lsp + +`bazelrc-lsp` is a LSP for `.bazelrc` configuration files. + +The `.bazelrc` file type is not detected automatically, you can register it manually (see below) or override the filetypes: + +```lua +vim.filetype.add { + pattern = { + ['.*.bazelrc'] = 'bazelrc', + }, +} +``` +]], + }, +} -- cgit v1.2.3-70-g09d2