jdtls for both windows/linux and add diagnostic keybind
This commit is contained in:
1 parent
6c9250d1da
commit
c51e3b30e7
2 files changed
+5
-1
No files matched your search
+3
-1
@@ -1,6 +1,8 @@
|
|||||||
|
local home = os.getenv("HOME") or os.getenv("USERPROFILE")
|
||||||
local config = {
|
local config = {
|
||||||
cmd = { os.getenv('HOME') .. '/.local/share/java/jdtls/bin/jdtls' },
|
cmd = { home .. '/.local/share/java/jdtls/bin/jdtls'},
|
||||||
root_dir = vim.fs.dirname(vim.fs.find({'gradlew', '.git', 'mvnw'}, { upward = true })[1]),
|
root_dir = vim.fs.dirname(vim.fs.find({'gradlew', '.git', 'mvnw'}, { upward = true })[1]),
|
||||||
}
|
}
|
||||||
|
|
||||||
require('jdtls').start_or_attach(config)
|
require('jdtls').start_or_attach(config)
|
||||||
|
|
||||||
@@ -32,3 +32,5 @@ vim.g.c_syntax_for_h = 1
|
|||||||
|
|
||||||
vim.cmd.colorscheme("moonfly")
|
vim.cmd.colorscheme("moonfly")
|
||||||
|
|
||||||
|
vim.keymap.set('n', '<leader>d', vim.diagnostic.open_float, { noremap = true, silent = true })
|
||||||
|
|
||||||
Reference in new issue
Block a user