-
Notifications
You must be signed in to change notification settings - Fork 36
Installing Julia with an IDE on Windows
Here is a recommended way how to install Julia on Windows to become quickly operational:
-
Create an environment variable
JULIA_DEPOT_PATHwith 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 noJULIA_DEPOT_PATHvariable is defined). -
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).
-
Add the Julia installation-directory to the PATH environment variable. Example:
PATH = "D:\<user-name>\programs\Julia-1.1.0\bin" -
Store the template startup.jl file at
C:\Users\<user-name>\.julia\config\startup.jland adapt the<path>variables. Whenever Julia is started, this startup file is executed.
This startup-file includes the activation of Julia packageRevise, 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). -
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 Themeand select a Color Theme (for example: "Quiet Light"). - Click
File / Preferences / Extensions. In the input field typejulia. Ajulia 0.11.1extension 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 / Juliaand de-selectJulia: 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. Typejuliain 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 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 selectCompare with Selected. You get then a nice representation of the difference.
- Start the editor and click
-
Currently (Feb. 22, 2019), there is no satisfactory Julia plot package available. The best option is to use matplotlib from Python. The installation is described in this wiki page.