diff options
| author | Dmitrii Morozov <dmitrii.morozov@sbb.ch> | 2025-10-27 14:45:12 +0100 |
|---|---|---|
| committer | Dmitrii Morozov <dmitrii.morozov@sbb.ch> | 2025-10-27 14:45:12 +0100 |
| commit | c5cc8ed0bc003085216eade1fb31b0950a453663 (patch) | |
| tree | b632349826c57f11376db58ea3e4fbfde61e846a /lua/plugins | |
| parent | fd49329ad98edf56536684799c46bd046dae9add (diff) | |
Configure springb-boot plugin properly
Diffstat (limited to 'lua/plugins')
| -rw-r--r-- | lua/plugins/jdtls.lua | 19 | ||||
| -rw-r--r-- | lua/plugins/spring-boot.lua | 15 |
2 files changed, 21 insertions, 13 deletions
diff --git a/lua/plugins/jdtls.lua b/lua/plugins/jdtls.lua new file mode 100644 index 0000000..49ab729 --- /dev/null +++ b/lua/plugins/jdtls.lua @@ -0,0 +1,19 @@ +return { + "mfussenegger/nvim-jdtls", + optional = true, + opts = { + jdtls = function(config) + if not vim.g.user_is_termux then + config.cmd = vim.list_extend(vim.deepcopy(config.cmd), { + "--jvm-arg=-Xms8g", + "--jvm-arg=-Xmx16g", + }) + end + if LazyVim.has("spring-boot.nvim") then + config.init_options = config.init_options or {} + config.init_options.bundles = + vim.list_extend(vim.deepcopy(config.init_options.bundles or {}), require("spring_boot").java_extensions()) + end + end, + }, +} diff --git a/lua/plugins/spring-boot.lua b/lua/plugins/spring-boot.lua index fba79d3..217115f 100644 --- a/lua/plugins/spring-boot.lua +++ b/lua/plugins/spring-boot.lua @@ -1,17 +1,6 @@ return { "JavaHello/spring-boot.nvim", ft = { "java", "yaml", "properties" }, - dependencies = { - "neovim/nvim-lspconfig", - }, - opts = function() - -- Add global command handlers - require("spring_boot").init_lsp_commands() - -- Add spring-boot jdtls extension jars - require("lspconfig").jdtls.setup({ - init_options = { - bundles = require("spring_boot").java_extensions(), - }, - }) - end, + ---@type bootls.Config|{} + opts = {}, } |
