Reference Address: https://blog.csdn.net/qq_36743482/article/details/78317549
1. Download Scala: http://www.scala-lang.org/download/
Install Scala
1, home directory, create a directory scala
mkdir scala
2, the scala mobile to create a directory and extract
mv-scale 2.12.3 .tgz scale
tar -zvxf-scale 2.12.3.tgz
3, open / etc / profile, or ~ / .bashrc configuration environment variable
sudo vim /etc/profile
or
sudo vim ~/.bashrc
In the final configuration add content
export SCALA_HOME=/home/yzh/scala/scala-2.12.3
export PATH=${SCALA_HOME}/bin:$PATH
Note: / etc / profile for all user variables; ~ / .bashrc for the current user
Note: If the author of this PATH variable it all together, and through ":" separated, we must ensure that the path variable in all HOME behind the variables.
The variables to take effect
source /etc/profile
or
source ~/.bashrc
Execution scala, where there is the interface installation is successful
Enter the following command to exit scala
:quit