Skip to content

Installing Julia with an IDE on Windows

Martin Otter edited this page Feb 23, 2019 · 8 revisions

Here is a recommended way how to install Julia on Windows to become quickly operational:

  1. Create an environment variable JULIA_DEPOT_PATH with a path where the Julia packages shall be stored. Example:
    JULIA_DEPOT_PATH = "D:\<user-name>\.julia".
    Note, C:\users\<user-name> has usually severe memory restrictions in organizations because this directory is synchronized in networks. In such a case, it is not practical to store the huge Julia package directory here (this is the default location if no JULIA_DEPOT_PATH variable is defined).

  2. Download Julia from https://julialang.org/downloads/. Note, the windows self-extracting archive can be unzipped at every location where the user has write access (so no administrator righs are needed).

  3. Add the Julia installation-directory to the PATH environment variable. Example:
    PATH = "D:\<user-name>\programs\Julia-1.1.0\bin"

  4. Store the template startup.jl file at C:\Users\<user-name>\.julia\config\startup.jl and adapt the <path> variables. Whenever Julia is started, this startup file is executed.
    This startup-file includes the activation of Julia package Revise, which is important for Julia development: Whenever code is changed, Revise compiles the changed code on-the-fly (otherwise, Julia would have to be restarted in order that the code changes become effective).

  5. There are several Editors and IDEs for Julia. All of them are currently (Feb. 22, 2019) missing a graphical debugger, so they are not fully satisfactory. If you have no strong preference, it is recommended to use Visual Studio Code, because this is a very fast editor with Julia syntax highlighting, terminal, good workflows, and useful default settings (fonts, font size, font color, etc.).
    Download Visual Studio Code from https://code.visualstudio.com/ and install it (no administrator rights are needed; not much space needed either - about 50 Mbyte):

    • Start the editor and click File / Preferences / Color Theme and select a Color Theme (for example: "Quiet Light").
    • Click File / Preferences / Extensions. In the input field type julia. A julia 0.11.4 extension is then show. Click on it to install it (you can get more information about this extension at https://github.com/JuliaEditorSupport/julia-vscode).
    • Click File / Preferences / Extensions / Julia and de-select Julia: Use Plot Pane. If this is selected, then no plot figure appears when using PyPlot.
    • Click Terminal / New Terminal. A new terminal window appears in the lower part of the window. Type julia in the terminal. This will start a julia shell (REPL).
    • Click on the first button in the left vertical tool bar to get a directory browser.
    • Select a Julia file. With F5, a julia shell (REPL) is started in the terminal if not yet present and then the command include("<absolute-path-of-selected-file>") is executed in the REPL.
    • Comparing files: Right click on the first file and select Select for Compare. Then right click on the second file and select Compare with Selected. You get then a nice representation of the difference.
  6. Currently (Feb. 22, 2019), there is no satisfactory Julia plot package available. The best option is to use PyPlot (= matplotlib) from Python. The installation is described in this wiki page. Note, every Python package can be used in Julia via the Julia package PyCall.

Clone this wiki locally