How to Install Kotlin compiler in Ubuntu 18.04/16.04


This quick tutorial is going to show you how to install the command line Kotlin compiler in Ubuntu 16.04, Ubuntu 17.10, Ubuntu 18.04.

Kotlin is a statically typed programming language that runs on the Java virtual machine and also can be compiled to JavaScript source code or use the LLVM compiler infrastructure.

Kotlin is a fully supported programming language by Google on the Android, and is directly included in the Android Studio 3.0 IDE package as an alternative to the standard Java compiler.

Kotlin is available as snap, the universal Linux package format, so it can be easily installed via following steps in Ubuntu.

1. (only for Ubuntu 16.04) Install the snapd daemon for those never installed a snap package.

Open terminal via Ctrl+Alt+T or by searching for ‘terminal’ from app launcher. When it opens, run command:

sudo apt-get install snapd snapd-xdg-open

Input your password (no visual feedback while typing due to security reason) when it prompts and hit Enter.


2. Then open Ubuntu Software, search for and install Kotlin.


You can also run the command below in terminal to install the snap:

snap install kotlin


About ml

ml is a part time stay-at-home dad who've been using Ubuntu Desktop for a few years. He writes in the free time and wishes to share some useful tips with Ubuntu beginners and lovers.