From 1d61643bd1c153a73ec89eaece1d497a4a8de444 Mon Sep 17 00:00:00 2001 From: fiplox Date: Sun, 1 Jan 2023 20:12:55 +0100 Subject: [PATCH] add null ls embedded --- lazy-lock.json | 3 ++- lua/config/mappings.lua | 5 +++-- lua/plugins/null-ls.lua | 5 +++++ 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/lazy-lock.json b/lazy-lock.json index 84bbd65..2fc748c 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -13,10 +13,11 @@ "lsp": { "branch": "master", "commit": "6b43ce561d97412cc512b569db6938e44529293e" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "aa25b4153d2f2636c3b3a8c8360349d2b29e7ae3" }, "mason.nvim": { "branch": "main", "commit": "8fd6559eecbabb39c68d147f1b2cccb8d2d2d2a1" }, + "null-ls-embedded": { "branch": "main", "commit": "a88d4d04f78717b38d257c5689db49f573240fb4" }, "null-ls.nvim": { "branch": "main", "commit": "d09d7d82cc26d63673cef85cb62895dd68aab6d8" }, "nvim-autopairs": { "branch": "master", "commit": "03580d758231956d33c8dd91e2be195106a79fa4" }, "nvim-cmp": { "branch": "main", "commit": "c49ad26e894e137e401b1d294948c46327877eaf" }, - "nvim-colorizer.lua": { "branch": "master", "commit": "36c610a9717cc9ec426a07c8e6bf3b3abcb139d6" }, + "nvim-colorizer.lua": { "branch": "master", "commit": "760e27df4dd966607e8fb7fd8b6b93e3c7d2e193" }, "nvim-snippy": { "branch": "master", "commit": "834820d5441e9c26de4bea4de95de5e117c058a5" }, "nvim-treesitter": { "branch": "master", "commit": "3a621b9a8362fac358d828254485024986d6d81b" }, "plenary.nvim": { "branch": "master", "commit": "4b7e52044bbb84242158d977a50c4cbcd85070c7" }, diff --git a/lua/config/mappings.lua b/lua/config/mappings.lua index 31cc1ff..dd7d607 100644 --- a/lua/config/mappings.lua +++ b/lua/config/mappings.lua @@ -145,7 +145,7 @@ local opts = { -- leader mappings {{{ -- TODO create entire treesitter section local mappings = { - [''] = {'Lf', 'Lf'}, + [''] = { 'Lf', 'Lf' }, ['rr'] = 'Search and replace all', ['rs'] = 'Search and replace', -- ["b"] = {"FindrBuffers", "List buffers"}, @@ -166,7 +166,8 @@ local mappings = { ['g'] = { 'Lazygit', 'Lazygit' }, l = { name = 'LSP', - f = 'Format', + f = { 'lua vim.lsp.buf.format { async = true }', 'Format' }, + e = { 'Lazy load null-ls.nvim', 'Enable null-ls' }, i = 'Lsp Info', a = 'Code action', j = 'Next diagnostic', diff --git a/lua/plugins/null-ls.lua b/lua/plugins/null-ls.lua index 6090071..acf186b 100644 --- a/lua/plugins/null-ls.lua +++ b/lua/plugins/null-ls.lua @@ -1,5 +1,9 @@ local M = { 'jose-elias-alvarez/null-ls.nvim', + dependencies = { + 'LostNeophyte/null-ls-embedded', + }, + ft = 'markdown', } function M.config() @@ -56,6 +60,7 @@ function M.config() filetypes = { 'asm', 's' }, }, -- diagnostics.flake8 + require('null-ls-embedded').nls_source, }, } end