From 169cd673f595b8802bc29888e037107d00d7d0f2 Mon Sep 17 00:00:00 2001 From: pml68 Date: Tue, 3 Dec 2024 20:29:10 +0100 Subject: feat(plugins): add workspace-diagnostics.nvim and ccc.nvim --- lua/pml68/configs/lspconfig.lua | 3 +++ lua/pml68/plugins/colors.lua | 14 +++++++------- lua/pml68/plugins/other.lua | 3 +++ lua/pml68/remap.lua | 8 ++++++-- 4 files changed, 19 insertions(+), 9 deletions(-) (limited to 'lua') diff --git a/lua/pml68/configs/lspconfig.lua b/lua/pml68/configs/lspconfig.lua index 8d16958..55f2d6f 100644 --- a/lua/pml68/configs/lspconfig.lua +++ b/lua/pml68/configs/lspconfig.lua @@ -38,6 +38,9 @@ vim.api.nvim_create_autocmd({ "BufEnter" }, { for _, server in pairs(servers) do local opts = { capabilities = capabilities, + on_attach = function(client, bufnr) + require("workspace-diagnostics").populate_workspace_diagnostics(client, bufnr) + end } local require_ok, conf_opts = pcall(require, "pml68.configs.settings." .. server) diff --git a/lua/pml68/plugins/colors.lua b/lua/pml68/plugins/colors.lua index 2587409..6a8eb36 100644 --- a/lua/pml68/plugins/colors.lua +++ b/lua/pml68/plugins/colors.lua @@ -1,13 +1,13 @@ return { { - "brenoprata10/nvim-highlight-colors", + "uga-rosa/ccc.nvim", event = { "BufReadPost", "BufNewFile" }, - config = function() - require("nvim-highlight-colors").setup({ - render = 'background', - enable_tailwind = true, - }) - end + opts = { + highlighter = { + auto_enable = true, + lsp = true, + }, + }, }, { "rose-pine/neovim", diff --git a/lua/pml68/plugins/other.lua b/lua/pml68/plugins/other.lua index cf7a888..d415f0b 100644 --- a/lua/pml68/plugins/other.lua +++ b/lua/pml68/plugins/other.lua @@ -8,6 +8,9 @@ return { "christoomey/vim-tmux-navigator", lazy = false, }, + { + "artemave/workspace-diagnostics.nvim", + }, { "lukas-reineke/indent-blankline.nvim", main = "ibl", diff --git a/lua/pml68/remap.lua b/lua/pml68/remap.lua index 8cfd1d7..9da8f91 100644 --- a/lua/pml68/remap.lua +++ b/lua/pml68/remap.lua @@ -4,7 +4,7 @@ vim.keymap.set("n", "n", "set nu!") vim.keymap.set("n", "rn", "set rnu!") vim.keymap.set("n", "", "nohl") vim.keymap.set("n", "x", "bd") -vim.keymap.set("n", "fo", "=ap") +vim.keymap.set("n", "fb", "=ap") vim.keymap.set("n", "", "!chmod 755 %", { silent = true }) vim.keymap.set("n", "", "ddp") vim.keymap.set("n", "", "ddkP") @@ -38,6 +38,9 @@ vim.keymap.set("n", "", "TmuxNavigateUp") -- Cellular Automaton vim.keymap.set("n", "gol", "CellularAutomaton game_of_life") +-- Color picker +vim.keymap.set("n", "cc", "CccPick") + -- VimTex vim.keymap.set("n", "ll", "VimtexCompile") vim.keymap.set("n", "vl", "VimtexView") @@ -54,10 +57,11 @@ vim.keymap.set("n", "sk", "Screenkey") -- Telescope vim.keymap.set('n', 'ff', "Telescope find_files", {}) vim.keymap.set('n', 'fw', "Telescope live_grep", {}) -vim.keymap.set('n', 'fb', "Telescope buffers", {}) +vim.keymap.set('n', 'fo', "Telescope buffers", {}) vim.keymap.set('n', 'fh', "Telescope help_tags", {}) vim.keymap.set('n', 'fz', "Telescope current_buffer_fuzzy_find", {}) vim.keymap.set('n', 'fg', "Telescope git_files", {}) +vim.keymap.set('n', 'fd', "Telescope diagnostics", {}) -- Diagnostics, LSP vim.keymap.set('n', 'gl', 'lua vim.diagnostic.open_float()') -- cgit v1.2.3