disable null_ls debig
This commit is contained in:
parent
d7a68e4c4f
commit
fb50b6125a
|
@ -4,6 +4,7 @@ if not setup then
|
||||||
end
|
end
|
||||||
|
|
||||||
local formatting = null_ls.builtins.formatting
|
local formatting = null_ls.builtins.formatting
|
||||||
|
local diagnostics = null_ls.builtins.diagnostics
|
||||||
local conditional = function(fn)
|
local conditional = function(fn)
|
||||||
local utils = require("null-ls.utils").make_conditional_utils()
|
local utils = require("null-ls.utils").make_conditional_utils()
|
||||||
return fn(utils)
|
return fn(utils)
|
||||||
|
@ -26,11 +27,17 @@ local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
|
||||||
local rubocop = null_ls.builtins.formatting.rubocop
|
local rubocop = null_ls.builtins.formatting.rubocop
|
||||||
|
|
||||||
null_ls.setup({
|
null_ls.setup({
|
||||||
debug = true,
|
debug = false,
|
||||||
sources = {
|
sources = {
|
||||||
formatting.prettier,
|
formatting.prettier,
|
||||||
formatting.stylua,
|
formatting.stylua,
|
||||||
null_ls.builtins.code_actions.gitsigns,
|
null_ls.builtins.code_actions.gitsigns,
|
||||||
|
-- setting eslint_d only if we have a ".eslintrc.js" file in the project
|
||||||
|
diagnostics.eslint_d.with({
|
||||||
|
condition = function(utils)
|
||||||
|
return utils.root_has_file({ '.eslintrc.js' })
|
||||||
|
end
|
||||||
|
}),
|
||||||
|
|
||||||
-- Here we set a conditional to call the rubocop formatter. If we have a Gemfile in the project, we call "bundle exec rubocop", if not we only call "rubocop".
|
-- Here we set a conditional to call the rubocop formatter. If we have a Gemfile in the project, we call "bundle exec rubocop", if not we only call "rubocop".
|
||||||
conditional(function(utils)
|
conditional(function(utils)
|
||||||
|
|
Loading…
Reference in New Issue