First, download Scala installation package
From the official Scala website address: http://www.scala-lang.org/download/Download Scala binary package, in 2.11.8 version For example two, installation
1. Move the downloaded binary package to the/usr/local directory and unzip the package
Tar zxvf scala-2.11.8.tgz
MV scala-2.11.8 Scala//rename Directory
2. Set environment variable
Vi/etc/profile
After opening, add the following configuration at the bottom of the document:
Export Path=/usr/local/scala/bin: $PATH
: wq! save Exit, execute the following command to make the change take effect
Source/etc/profile
3. Check if Scala is installed successfully
Execute Scala command on the terminal
Scala
If you see the Scala version and related information, the installation is successful.
Welcome to Scala 2.11.8 (Java HotSpot (TM) 64-bit Server VM, Java 1.8.0_111).
Type in expressions for evaluation. Or Try:help.
Or execute the following Scala command
Scala-version
If you see the Scala version information, the installation is successful.
Scala Code Runner version 2.11.8--Copyright 2002-2016, LAMP/EPFL