Neovim for Beginners — Java

Use Neovim for Java application development.

alpha2phi

--

Neovim for Beginners — Java

We have already configured Neovim for languages like Python, JavaScript, TypeScript, Rust, Go, Lua, HTML, etc. In this article, let’s check out how we can use Neovim for Java application development.

This article is part of the Neovim for Beginners series.

The Neovim configuration files can be found in this repository.

Getting Started

Java Development Kit (JDK)

Depending on the operating system, we need to install OpenJDK or Oracle JDK.

Language Server

For the language server, we can use eclipse.jdt.ls.Installing the language server is easy by using nvim-lsp-installer.

Type the command :LspInstall jdtls to install the language server. Alternatively, type the command :LspInstallInfo, select jdtls and press i to install.

Install Language Server

The installation folder can be found under the standard path location.

local JDTLS_LOCATION = vim.fn.stdpath "data" .. "/lsp_servers/jdtls"

--

--

alpha2phi

Software engineer, Data Science and ML practitioner.