Scala linux ��� ���

Download Scala 2

First, make sure you have the Java 8 JDK (or Java 11 JDK) installed.

To check, open the terminal and type:

java -version (Make sure you have version 1.8 or 11.)

(If you don’t have it installed, download Java from Oracle Java 8, Oracle Java 11, or AdoptOpenJDK 8/11. Refer JDK Compatibility for Scala/Java compatiblity detail.

Then, install Scala:

. either by installing an IDE such as IntelliJ, or sbt, Scala’s build tool.

Best if you prefer a full-featured IDE (recommended for beginners)

Best if you are familiar with the command line

Compared to other programming languages, installing Scala is a bit unusual. Scala is unusual because it is usually installed for each of your Scala projects rather than being installed system-wide. Both of the above options manage (via sbt) a specific Scala version per Scala project you create.

But it’s also possible to «install» Scala in numerous other ways; e.g., grab Scala binaries and use Scala from the command line or use Scala in your browser!

Other ways to install Scala

  • Download the Scala binaries for
    Need help running the binaries?
  • Using SDKMAN!, you can easily install specific versions of Scala on any platform with sdk install scala 2.13.6
  • On macOS you can also use Homebrew and existing Scala Formulae
    brew update
    brew install scala
  • With MacPorts, you can get Scala using sudo port install scala2.x command.
    For example to install Scala 2.12 simply use sudo port install scala2.12
  • Use Scastie to run single-file Scala programs in your browser using multiple Scala compilers; the production Scala 2.x compilers, Scala.js, Dotty, and Typelevel Scala. Save and share executable Scala code snippets.
  • Try Scala in the browser via ScalaFiddle. This lets you run single-file Scala programs in your browser using Scala.js, including graphical/interactive examples such as Oscilloscope or Ray Tracer
  • Get Ammonite, a popular Scala REPL

Or are you looking for previous releases of Scala?

Читайте также:  Обновить до windows 10 mobile lumia 735

Release Notes

Other Releases

You can find the links to prior versions or the latest development version below. To see a detailed list of changes for each version of Scala please refer to the changelog.

Note that different major releases of Scala (e.g. Scala 2.11.x and Scala 2.12.x) are not binary compatible with each other.

  • Latest 2.12.x maintenance release:
    • Scala 2.12.15 — Released on September 14, 2021
  • Last 2.11.x maintenance release:
    • Scala 2.11.12 — Released on November 9, 2017
  • Last 2.10.x maintenance release:
    • Scala 2.10.7 — Released on November 9, 2017
  • Nightly builds
  • Changelog
  • All previous releases

Other resources

You can find the installer download links for other operating systems, as well as documentation and source code archives for Scala 2.13.6 below.

Archive System Size
scala-2.13.6.tgz Mac OS X, Unix, Cygwin 22.32M
scala-2.13.6.msi Windows (msi installer) 131.46M
scala-2.13.6.zip Windows 22.36M
scala-2.13.6.deb Debian 646.94M
scala-2.13.6.rpm RPM package 131.73M
scala-docs-2.13.6.txz API docs 58.10M
scala-docs-2.13.6.zip API docs 112.56M
scala-sources-2.13.6.tar.gz Sources

License

The Scala distribution is released under the Apache License, Version 2.0.

Источник

Scala 2.11.12

First, make sure you have the Java 8 JDK (or Java 11 JDK) installed.

To check, open the terminal and type:

java -version (Make sure you have version 1.8 or 11.)

(If you don’t have it installed, download Java from Oracle Java 8, Oracle Java 11, or AdoptOpenJDK 8/11. Refer JDK Compatibility for Scala/Java compatiblity detail.

Then, install Scala:

. either by installing an IDE such as IntelliJ, or sbt, Scala’s build tool.

Best if you prefer a full-featured IDE (recommended for beginners)

Best if you are familiar with the command line

Compared to other programming languages, installing Scala is a bit unusual. Scala is unusual because it is usually installed for each of your Scala projects rather than being installed system-wide. Both of the above options manage (via sbt) a specific Scala version per Scala project you create.

But it’s also possible to «install» Scala in numerous other ways; e.g., grab Scala binaries and use Scala from the command line or use Scala in your browser!

Other ways to install Scala

  • Download the Scala binaries for
    Need help running the binaries?
  • Using SDKMAN!, you can easily install specific versions of Scala on any platform with sdk install scala 2.13.6
  • On macOS you can also use Homebrew and existing Scala Formulae
    brew update
    brew install scala
  • With MacPorts, you can get Scala using sudo port install scala2.x command.
    For example to install Scala 2.12 simply use sudo port install scala2.12
  • Use Scastie to run single-file Scala programs in your browser using multiple Scala compilers; the production Scala 2.x compilers, Scala.js, Dotty, and Typelevel Scala. Save and share executable Scala code snippets.
  • Try Scala in the browser via ScalaFiddle. This lets you run single-file Scala programs in your browser using Scala.js, including graphical/interactive examples such as Oscilloscope or Ray Tracer
  • Get Ammonite, a popular Scala REPL

Or are you looking for previous releases of Scala?

Release Notes

Other Releases

You can find the links to prior versions or the latest development version below. To see a detailed list of changes for each version of Scala please refer to the changelog.

Note that different major releases of Scala (e.g. Scala 2.11.x and Scala 2.12.x) are not binary compatible with each other.

Other resources

You can find the installer download links for other operating systems, as well as documentation and source code archives for Scala 2.11.12 below.

Archive System Size
scala-2.11.12.tgz Mac OS X, Unix, Cygwin 27.77M
scala-2.11.12.msi Windows (msi installer) 109.82M
scala-2.11.12.zip Windows 27.82M
scala-2.11.12.deb Debian 76.44M
scala-2.11.12.rpm RPM package 108.60M
scala-docs-2.11.12.txz API docs 46.17M
scala-docs-2.11.12.zip API docs 84.26M
scala-sources-2.11.12.tar.gz Sources

License

The Scala distribution is released under the 3-clause BSD license.

Источник

How to Install Scala in Linux?

Before, we start with the process of Installing Scala on our System. We must have first-hand knowledge of What the Scala Language is and what it actually does? Scala is a general-purpose, high-level, multi-paradigm programming language. It is a pure object-oriented programming language which also provides the support to the functional programming approach. There is no concept of primitive data as everything is an object in Scala. It is designed to express the general programming patterns in a refined, succinct, and type-safe way. Scala programs can convert to bytecodes and can run on the JVM(Java Virtual Machine). Scala stands for Scalable language. It also provides the Javascript runtimes. Scala is highly influenced by Java and some other programming langauges like Lisp, Haskell, Pizza etc.
Scala is a very compatible language and thus can very easily be installed into the Linux Operating System. The most basic requirement is that we must have Java 1.8 or a greater version installed on our computer.

Verifying Java Packages:
The first thing we need to have is a Java Software Development Kit(SDK) installed on the computer. We need to verify these SDK packages and if not installed then install them. Just go to the Terminal and run the following command:

Once this command is executed the output will show the java version and the output will be as follows:

In case we are not having the SDK installed then download the latest version according to the computer requirements by using the following command:

Downloading and Installing Scala:

Downloading Scala:
Before starting with the installation process, you need to download it. For that, all versions of Scala for Linux are available on scala-lang.org

Download the Scala and follow the further instructions for the installation of Scala. However, one can easily install latest version of Scala on Ubuntu with the use of following command:

Beginning with the Installation:

  • Getting Started:
  • Starting the Installation Process:
  • Finished Installation:

After completing the installation process, any IDE or text editor can be used to write Scala Codes and Run them on the IDE or the Terminal with the use of command:

Here’s a sample Program to begin with the use of Scala Programming:
Let’s consider a simple Hello World Program.

Источник

Download Scala 3

Getting Started with Scala 3

Depending on your experience and your requirements, there exist two ways to install Scala 3 on your computer, either through sbt, or through Coursier.

Best if you want to get started quickly.

Coursier will install all the necessary dependencies for you, so after installing Coursier you are ready to go.

Best if you want to work on larger projects.

If you already have sbt installed, it is very easy to switch to Scala version 3.0.2.

Installing Scala 3 with Coursier

Install the Coursier Scala artifact fetcher.

Visit the Coursier website for detailed installation instructions on how to install Coursier.

(Coursier is the simplest way to get started with Scala, since it will automatically download and install all necessary dependencies for you).

(Running this command installs the correct Java version along with some other helpful command line tools).

Then, install Scala 3

Open a terminal and run the following commands:

cs install scala3-compiler to install the Scala 3 compiler.

cs install scala3-repl to install the Scala 3 interactive read-eval-print loop.

Use Scala 3

The command scala3-repl will start a Scala console that you can use to interactively evaluate Scala programs. Within this console, run the command :load test.scala to load and execute the file test.scala .

To use the Scala 3 compiler to compile a file test.scala simply run scala3-compiler test.scala in your terminal.

Installing Scala 3 with sbt

First, make sure you have the Java 8 JDK (or Java 11 JDK) installed.

To check, open the terminal and type:

java -version (Make sure you have version 1.8 or 11.)

The environment variable JAVA_HOME should point to your Java installation.

(If you don’t have it installed, download Java from Oracle Java 8, Oracle Java 11, or AdoptOpenJDK 8/11. Refer JDK Compatibility for Scala/Java compatiblity detail.

Install the sbt build tool.

Visit the sbt website for detailed installation instructions on how to install sbt.

(sbt is a build tool that allows you to compile, run, test, and deploy your Scala projects).

Create a project and use Scala 3

To create a new Scala 3 project, go to your terminal and run sbt new scala/scala3.g8 .

After entering the name of your project (let’s say MyProject ), in your terminal go to the generated folder (for example myproject ) and run the command sbt run .

You should be greeted with a friendly message.

(Following conventions for the directory structure, the Scala source files are located under src/main/scala ).

Other ways to install Scala

  • Download the Scala binaries for 3.0.2 at github.
    Need help running the binaries?
  • Using SDKMAN!, you can easily install the latest version of Scala on any platform by running the following command:
    sdk install scala
  • On macOS you can also use Homebrew and run the following commands:
    brew update
    brew install lampepfl/brew/dotty
  • Use Scastie to run single-file Scala programs in your browser using multiple Scala compilers; the production Scala 2.x compilers, Scala.js, Scala 3, and Typelevel Scala. Save and share executable Scala code snippets.

Or are you looking for previous releases of Scala?

Release Notes

License

The Scala distribution is released under the Apache License, Version 2.0.

Источник

Читайте также:  Viewing on windows mobile
Оцените статью