init.lua 1.2 KB

123456789101112131415161718192021222324252627
  1. -- 1. get the config for this server from nvim-lspconfig and adjust the cmd path.
  2. -- relative paths are allowed, lspinstall automatically adjusts the cmd and cmd_cwd for us!
  3. -- local config = require("lspconfig").jdtls.document_config
  4. -- require("lspconfig/configs").jdtls = nil -- important, unset the loaded config again
  5. -- config.default_config.cmd[1] = "./node_modules/.bin/bash-language-server"
  6. -- 2. extend the config with an install_script and (optionally) uninstall_script
  7. -- require'lspinstall/servers'.jdtls = vim.tbl_extend('error', config, {
  8. -- -- lspinstall will automatically create/delete the install directory for every server
  9. -- install_script = [[
  10. -- git clone https://github.com/eclipse/eclipse.jdt.ls.git
  11. -- cd eclipse.jdt.ls
  12. -- ./mvnw clean verify
  13. -- ]],
  14. -- uninstall_script = nil -- can be omitted
  15. -- })
  16. -- require'lspinstall/servers'.kotlin = vim.tbl_extend('error', config, {
  17. -- install_script = [[
  18. -- git clone https://github.com/fwcd/kotlin-language-server.git language-server
  19. -- cd language-server
  20. -- ./gradlew :server:installDist
  21. -- ]],
  22. -- uninstall_script = nil -- can be omitted
  23. -- })
  24. require("lspinstall").setup()