DEV Community

Bing Pan
Bing Pan

Posted on

Setting Up Eclipse With Plugins On Ubuntu

Vim:

For a first-timer who sets up java development environment on Ubuntu, one should not use Vim as the primary IDE option even though it is a very powerful tool.

Initially, after finding a Youtube video titled as Java Programming Using Command Line Tools Only! (vim, curl, and tmux) at https://www.youtube.com/watch?v=zmnlpf4FtkE, I decided to use Vim for Java development on Ubuntu. Since it is recommended to use prettier as my source code formatter, I was very happy to find this Youtube video How to automatically format your code in VIM with Prettier | VIM Tutorial at https://www.youtube.com/watch?v=ellaT6dK780. However, later on, I found out Java is not included in the list that prettier will support in Vim.

Then, check out the documentation at prettier.io, and followed the instructions on vim-prettier at https://github.com/prettier/vim-prettier. Unfortunately, my installation failed at the beginning of the instruction, which states:
To install with vim 8+ plugins, simply clone to your ~/.vim/pack/plugins/start directory, and add packloadall to your .vimrc (if you haven't already).
mkdir -p ~/.vim/pack/plugins/start
git clone https://github.com/prettier/vim-prettier ~/.vim/pack/plugins/start/vim-prettier

.vimrc: packloadall

When Vim option failed miserably, I decided to give another try on SpaceVim at https://spacevim.org/quick-start-guide/. The installation went through very smoothly and I could use it to work on my java project. But the final straw for me to give up on SpaceVim was the failure to configure its layer to java.

After all the time and energy spent, I finally realized Vim is not a feasible option for my time frame. I abandoned Vim.

Eclipse

At the very beginning, I was reluctant to a non-linux ide such as Eclipse. As the deadline of my lab is approaching, Eclipse seems the only option I can resort to.

It is a breeze to use install Eclipse on Ubuntu. Integrating Eclipse with a source code formatter and a linter is also very easy. By using Google Java Format as the Formatter.xml file, I set Save Actions options to format all lines of source code via Eclipse's preference for editor. In addition, through Eclipse MarketPlace, I installed Spotbugs plugin as the linter.

Top comments (0)