Skip to content
Snippets Groups Projects
tools-setup.md 5.99 KiB

Tools Setup

Note

We recommend using Linux or macOS for this course, we also support Windows but typically people have more trouble getting everything working correctly on Windows and it's harder for us to help them since we don't use Windows ourselves.

On Windows, if your username has spaces or special characters in it, the IDE might not work properly. Please create a new user with a username containing only letters.

Step 1: Create an account on gitlab.epfl.ch

If you haven't already log into gitlab and fill in this table with your GASPAR and SCIPER number to initialize your GitLab repository for the course. Do this as soon as possible because it will take some time between the account creation and the lab submission system working for your account.

Step 2: Installing the Java Development Kit (JDK) and sbt via coursier

We will use coursier to install the correct version of Java as well as the sbt build tool:

On Linux

curl -fLo cs https://git.io/coursier-cli-linux
chmod +x cs
./cs setup -y --jvm 8 --apps cs,sbt

On macOS

First, install the Homebrew package manager:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

Use Homebrew to install coursier:

brew install coursier/formulas/coursier
[ -f ~/.bash_profile ] && sudo chmod 0666 ~/.bash_profile
cs setup -y --jvm 8 --apps sbt

On Windows

Download and install the Visual C++ 2010 SP1 Redistributable Package.

Open cmd.exe (and not powershell)

First, make sure that you are not in the System32 directory, instead you should be in C:\Users\yourusername. If you are in System32 you will need to change directory to your user directory every time you start a terminal by running:

cd %USERPROFILE%

Now assuming that you're in the correct directory you can run:

bitsadmin /transfer cs-cli https://git.io/coursier-cli-windows-exe "%cd%\cs.exe"
.\cs setup -y --jvm 8 --apps cs,sbt

(This command might cause your anti-virus to misidentify cs.exe as a virus, please override that, that might require temporarily turning off your anti-virus during this setup).

If this command fails with Error running powershell script, use the following alternative instructions (if the command didn't fail, continue to the next step):

  1. Run .\cs setup --jvm 8 --apps cs,sbt, at every question answer "n" and press Enter.
  2. The last question should look like "Should we add C:\...\bin to your PATH?", please copy the C:\...\bin part here.
  3. Edit the Path environment variable and paste the path you just copied to it, see https://www.architectryan.com/2018/08/31/how-to-change-environment-variables-on-windows-10/ and make sure the path you're adding is the first entry in the Path environment variable.
  4. Start a new cmd.exe and continue with the rest of the instructions