Lately I’ve been in the process of “making the switch” from macOS to Linux Mint, and to that end, I just installed the Java 8 JDK/SDK, Scala 2.12, and SBT 0.13 on a new Linux Mint system, and I want to note here how I did that while it’s still fresh in my mind. Here are my notes in a compact form.
Installing the Java 8 JDK on Mint
The latest information I found on installing the Java JDK/SDK on Mint was at this tipsonubuntu page.
sudo apt-get remove --purge openjdk* sudo add-apt-repository -y ppa:webupd8team/java sudo apt-get update sudo apt-get -y install oracle-java8-installer
or this instead of the last two, use these:
sudo apt update; sudo apt install oracle-java8-installer
I then did this, per the prompt from the previous command:
sudo apt install oracle-java8-set-default
After that, Intellij IDEA found this JDK easily.
Installing Scala on Linux Mint
Installing Scala on Mint was simple:
sudo apt install scala
This brought in the most current version of Scala available at the time of this writing in May, 2017, Scala 2.12.2.
Installing SBT on Mint
Instructions for installing SBT on Debian per the SBT website:
echo "deb https://dl.bintray.com/sbt/debian /" | sudo tee -a /etc/apt/sources.list.d/sbt.list sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 2EE0EA64E40A89B84B2DF73499E82A75642AC823 sudo apt-get update sudo apt-get install sbt
That did a lot of work that took a while, but later when I tried to use SBT, it did another download that took a long time:
> sbt test Getting org.scala-sbt sbt 0.13.15 (this may take some time)... ... lots of download-related info ... downloading https://repo.typesafe.com/typesafe/ivy-releases/org.scala-sbt/collections/0.13.15/jars/collections.jar ... [SUCCESSFUL ] org.scala-sbt#collections;0.13.15!collections.jar (2936ms) ... 'compiler-interface' not yet compiled for Scala 2.12.2. Compiling...
Installing Intellij IDEA
I have also been using Intellij IDEA. To do that I installed it from their website as a tar’d and gzip’d file, started
idea.sh from the command line, then mostly just followed the prompts. The key was getting Java and Scala properly installed. I suspect it’s best to install those first, but I installed IDEA first, then installed Java, Scala, and SBT.
It looks like IDEA installs its own copy of SBT, but I often run SBT from the command line myself, so I installed it with
I don’t remember the exact prompt, but at some point during the process, if you let IDEA install its own command to your desktop, that makes it easy to start it like a regular app.
Summary: Installing Java JDK, Scala, and SBT on Linux Mint
In summary, after these steps I was able to use the Java JDK/SDK, Scala, SBT, and Intellij IDEA on Linux Mint.
There’s just one person behind this website; if this article was helpful (or interesting), I’d appreciate it if you’d share it. Thanks, Al.