Install Julia locally to your $System

This article covers the local installation of Julia using packages from the Download Page. Other options for using Julia include an Online REPL, a Docker image, and a Desktop Julia IDE.

Installs can either be without sudo/admin USER or GLOBAL. For context, most other programming languages default to being installed with GLOBAL scope. Choose one and follow the instructins for that target.

Installation

Windows

  1. (Windows 7/Server 2012 only): Enable Windows Management Framework 3+

  2. Download the executable (32-bit / 64-bit)

  3. Open the executable with Admin Privileges

  4. GLOBAL | Change the install directory to %PROGRAMFILES%/Julia.

  5. Hit Install > Hit Finish

  6. GLOBAL | Using Powershell with Admin Privileges, add julia permanently to your path

    1
    2
    3
    4
    5
    6
    7
    
    $PATH = [Environment]::GetEnvironmentVariable("PATH")
    $julia_path = "C:\Program Files\Julia"
    
    # -DO THIS- For all users on this machine
    [Environment]::SetEnvironmentVariable("PATH", "$PATH;$julia_path", "Machine")
    # -OR THIS- For just me
    [Environment]::SetEnvironmentVariable("PATH", "$PATH;$julia_path")
    
  7. USER | Alias julia in your $Profile. If you do not have a profile, Set one up.

    1
    2
    
    $julia_path = $home\AppData\local\Julia-1.1.0\bin\julia
    Add-Content -Path $Profile -Value "function julia { Invoke-Expression $julia_path }"
    

Macos

  1. Get brew if not installed

  2. GLOBAL | brew cask install julia

  3. USER | Download, un/mount dmg, install to ~/Applications, add julia it to PATH

     1
     2
     3
     4
     5
     6
     7
     8
     9
    10
    11
    12
    13
    
    #!/usr/bin/env bash
    curl https://julialang-s3.julialang.org/bin/mac/x64/1.1/julia-1.1.0-mac64.dmg \
      -o /tmp/julia-1.1.0.dmg
    hdiutil attach /tmp/julia-1.1.0.dmg
    mkdir -p ~/Applications
    cp -r /Volumes/Julia-1.1.0/Julia-1.1.app ~/Applications/Julia-1.1
    ln -s ~/Applications/Julia-1.1/Contents/Resources/julia/bin/julia ~/Applications/julia
    hdiutil detach /Volumes/Julia-1.1.0
    
    if [[ ":$PATH:" != *":$HOME/Applications:"* ]]; then
    echo "export PATH=$PATH:$HOME/Applications" >> ~/.profile
      source ~/.profile
    fi
    

Linux

  1. Download the binary, depending on your architecture

    1
    2
    3
    4
    5
    6
    
    # Download 64-bit
    curl https://julialang-s3.julialang.org/bin/linux/x64/1.1/julia-1.1.0-linux-x86_64.tar.gz \
      -o /tmp/julia.tar.gz
    # Or 32-bit
    curl https://julialang-s3.julialang.org/bin/linux/x86/1.1/julia-1.1.0-linux-i686.tar.gz \
      -o /tmp/julia.tar.gz
    
  2. GLOBAL | Download, extract, and copy to /opt/local, add to PATH

    1
    2
    3
    4
    5
    6
    7
    
    tar -C /tmp -xzf /tmp/julia.tar.gz
    cp -r /tmp/julia /opt/local
    
    if [[ ":$PATH:" != *":/opt/local:"* ]]; then
      echo "export PATH=$PATH:/opt/local" >> ~/.profile
      source ~/.profile
    fi
    
  3. USER | Download, extract, copy to ~/bin, and add to PATH

    1
    2
    3
    4
    5
    6
    7
    8
    
    tar -C /tmp -xzf /tmp/julia.tar.gz
    mkdir -p ~/bin
    cp -r /tmp/julia ~/bin
    
    if [[ ":$PATH:" != *":~/bin:"* ]]; then
      echo "export PATH=$PATH:~/bin" >> ~/.profile
      source ~/.profile
    fi
    

Verification

Open a new shell to make sure julia==1.1.0 is installed correctly

Bash

Julia Install on Bash

Powershell

Julia Install on Powershell

Next Steps

Now that you have Julia, install some packages!