You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I found this issue when trying to use the plugin with nvim-java
Failed to run `config` for springboot-nvim
...e/nvim/lazy/springboot-nvim/lua/springboot-nvim/init.lua:6: module 'jdtls' not found:
^Ino field package.preload['jdtls']
cache_loader: module jdtls not found
cache_loader_lib: module jdtls not found
^Ino file './jdtls.lua'
^Ino file '/opt/homebrew/share/luajit-2.1/jdtls.lua'
^Ino file '/usr/local/share/lua/5.1/jdtls.lua'
^Ino file '/usr/local/share/lua/5.1/jdtls/init.lua'
^Ino file '/opt/homebrew/share/lua/5.1/jdtls.lua'
^Ino file '/opt/homebrew/share/lua/5.1/jdtls/init.lua'
^Ino file '/Users/piotr/.local/share/nvim/lazy-rocks/telescope.nvim/share/lua/5.1/jdtls.lua'
^Ino file '/Users/piotr/.local/share/nvim/lazy-rocks/telescope.nvim/share/lua/5.1/jdtls/init.lua'
^Ino file './jdtls.so'
^Ino file '/usr/local/lib/lua/5.1/jdtls.so'
^Ino file '/opt/homebrew/lib/lua/5.1/jdtls.so'
^Ino file '/usr/local/lib/lua/5.1/loadall.so'
^Ino file '/Users/piotr/.local/share/nvim/lazy-rocks/telescope.nvim/lib/lua/5.1/jdtls.so'
^Ino file '/Users/piotr/.local/share/nvim/lazy-rocks/telescope.nvim/lib64/lua/5.1/jdtls.so'
I think it is because of this local declaration in init.lua:
local jdtls = require("jdtls")
My plugin configuration:
{
"elmcgill/springboot-nvim",
dev = true,
dependencies = {
"neovim/nvim-lspconfig",
"nvim-java/nvim-java",
},
event = "VeryLazy",
config = function()
-- gain acces to the springboot nvim plugin and its functions
local springboot_nvim = require("springboot-nvim")
-- set a vim motion to <Space> + <Shift>J + r to run the spring boot project in a vim terminal
vim.keymap.set("n", "<leader>Jr", springboot_nvim.boot_run, { desc = "[J]ava [R]un Spring Boot" })
-- set a vim motion to <Space> + <Shift>J + c to open the generate class ui to create a class
vim.keymap.set("n", "<leader>Jc", springboot_nvim.generate_class, { desc = "[J]ava Create [C]lass" })
-- set a vim motion to <Space> + <Shift>J + i to open the generate interface ui to create an interface
vim.keymap.set(
"n",
"<leader>Ji",
springboot_nvim.generate_interface,
{ desc = "[J]ava Create [I]nterface" }
)
-- set a vim motion to <Space> + <Shift>J + e to open the generate enum ui to create an enum
vim.keymap.set("n", "<leader>Je", springboot_nvim.generate_enum, { desc = "[J]ava Create [E]num" })
-- run the setup function with default configuration
springboot_nvim.setup({})
end,
},
Expected:
possibility to use the plugin with nvim-java
The text was updated successfully, but these errors were encountered:
I found this issue when trying to use the plugin with nvim-java
I think it is because of this local declaration in init.lua:
My plugin configuration:
Expected:
The text was updated successfully, but these errors were encountered: