diff --git a/lazy-lock.json b/lazy-lock.json index 2231c66..e03a610 100644 --- a/lazy-lock.json +++ b/lazy-lock.json @@ -20,10 +20,11 @@ "jaq-nvim": { "branch": "master", "commit": "236296aae555657487d1bb4d066cbde9d79d8cd4" }, "lazy.nvim": { "branch": "main", "commit": "e27c9df5fe039e9d2833ef4fcf7305595d5ccda7" }, "live-server": { "branch": "main", "commit": "ecd7c1418823b65dd2bca710587c80afe42c973e" }, + "lsp_lines.nvim": { "branch": "main", "commit": "3b57922d2d79762e6baedaf9d66d8ba71f822816" }, "lualine.nvim": { "branch": "master", "commit": "e99d733e0213ceb8f548ae6551b04ae32e590c80" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "3924f2d264097b2caf13e713485dbc3e9d616574" }, "mason-null-ls.nvim": { "branch": "main", "commit": "29ce60f9a16fef3de682a9365ef635f24ae92bf9" }, - "mason.nvim": { "branch": "main", "commit": "87c9453cd91da3bba1076fa578a72439fbc4d311" }, + "mason.nvim": { "branch": "main", "commit": "de9ce244e27b0144959cb6cee1fc584bb00ccae4" }, "mini.animate": { "branch": "main", "commit": "b0c717ed5513b5f23e7c48615449c7dc9fabd05b" }, "mini.indentscope": { "branch": "main", "commit": "43f6761c9a3e397b7c12b3c72f678bcf61efcfcf" }, "neoscroll.nvim": { "branch": "master", "commit": "d7601c26c8a183fa8994ed339e70c2d841253e93" }, @@ -44,7 +45,7 @@ "nvim-ts-autotag": { "branch": "main", "commit": "fdefe46c6807441460f11f11a167a2baf8e4534b" }, "nvim-ts-context-commentstring": { "branch": "main", "commit": "729d83ecb990dc2b30272833c213cc6d49ed5214" }, "nvim-ts-rainbow": { "branch": "master", "commit": "ef95c15a935f97c65a80e48e12fe72d49aacf9b9" }, - "nvim-web-devicons": { "branch": "master", "commit": "f1b1cee3a561590a6c1637a9326c406f6e4af914" }, + "nvim-web-devicons": { "branch": "master", "commit": "2c07b4a1fe40284c61c4a40e6d0d769c198a27f5" }, "plenary.nvim": { "branch": "master", "commit": "253d34830709d690f013daf2853a9d21ad7accab" }, "smart-splits.nvim": { "branch": "master", "commit": "52b521618511b3a874255c8a717ace7155fd5f21" }, "symbols-outline.nvim": { "branch": "master", "commit": "512791925d57a61c545bc303356e8a8f7869763c" }, diff --git a/lua/config/lazy.lua b/lua/config/lazy.lua index 2be223e..92d288e 100644 --- a/lua/config/lazy.lua +++ b/lua/config/lazy.lua @@ -7,6 +7,7 @@ end vim.opt.rtp:prepend(vim.env.LAZY or lazypath) vim.g.mapleader = " " vim.g.maplocalleader = " " +vim.diagnostic.config({ virtual_lines = false }) require("lazy").setup({ spec = { { import = "plugins" }, diff --git a/lua/custom/default.lua b/lua/custom/default.lua index d99fa13..6dcf82f 100644 --- a/lua/custom/default.lua +++ b/lua/custom/default.lua @@ -85,7 +85,7 @@ vim.g.pcode_lsp_installer = { } -- use for lsp diagnostics virtual text -vim.g.pcode_lsp_virtualtext = true +vim.g.pcode_lsp_virtualtext = false -- use for lsp ghost text config vim.g.pcode_lspghost_text = true @@ -130,6 +130,11 @@ vim.g.pcode_whichkey = { j = { "Jaq float", "Run With Jaq" }, }, ["o"] = { "SymbolsOutline", "Symbol Outline" }, + ["m"] = { + name = "Minimap", + c = { "lua require('mini.map').close()", "Minimap Close" }, + o = { "lua require('mini.map').open()", "Minimap Open" }, + }, } -- https://github.com/CRAG666/code_runner.nvim diff --git a/lua/custom/plugins/lsp-line.lua b/lua/custom/plugins/lsp-line.lua new file mode 100644 index 0000000..f2ed498 --- /dev/null +++ b/lua/custom/plugins/lsp-line.lua @@ -0,0 +1,20 @@ +return { + "ErichDonGubler/lsp_lines.nvim", + event = "VimEnter", + config = function() + require("lsp_lines").setup() + vim.api.nvim_create_autocmd("FileType", { + pattern = { "*" }, --ini untuk file yang tidak ingin dibaca + callback = function() + local exclude_ft = { + "lazy", + } + if vim.tbl_contains(exclude_ft, vim.o.filetype) then + vim.diagnostic.config({ virtual_lines = false }) + else + vim.diagnostic.config({ virtual_lines = true }) + end + end, + }) + end, +} diff --git a/lua/custom/plugins/minimap.lua b/lua/custom/plugins/minimap.lua new file mode 100644 index 0000000..50cb7c2 --- /dev/null +++ b/lua/custom/plugins/minimap.lua @@ -0,0 +1,51 @@ +return { + -- "echasnovski/mini.map", + -- branch = "stable", + -- event = "BufRead", + -- config = function() + -- require("mini.map").setup() + -- local map = require("mini.map") + -- map.setup({ + -- integrations = { + -- map.gen_integration.builtin_search(), + -- map.gen_integration.diagnostic({ + -- error = "DiagnosticFloatingError", + -- warn = "DiagnosticFloatingWarn", + -- info = "DiagnosticFloatingInfo", + -- hint = "DiagnosticFloatingHint", + -- }), + -- }, + -- symbols = { + -- encode = map.gen_encode_symbols.dot("4x2"), + -- }, + -- window = { + -- side = "right", + -- width = 10, -- set to 1 for a pure scrollbar :) + -- winblend = 15, + -- show_integration_count = false, + -- }, + -- }) + -- + -- vim.api.nvim_create_autocmd("FileType", { + -- pattern = "*", + -- callback = function() + -- local exclude_ft = { + -- "qf", + -- "NvimTree", + -- "toggleterm", + -- "TelescopePrompt", + -- "alpha", + -- "netrw", + -- } + -- + -- local map = require("mini.map") + -- if vim.tbl_contains(exclude_ft, vim.o.filetype) then + -- vim.b.minimap_disable = true + -- map.close() + -- elseif vim.o.buftype == "" then + -- map.open() + -- end + -- end, + -- }) + -- end, +}