Search icon CANCEL
Subscription
0
Cart icon
Cart
Close icon
You have no products in your basket yet
Save more on your purchases!
Savings automatically calculated. No voucher code required
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Julia 1.0 Programming Cookbook

You're reading from  Julia 1.0 Programming Cookbook

Product type Book
Published in Nov 2018
Publisher Packt
ISBN-13 9781788998369
Pages 460 pages
Edition 1st Edition
Languages
Authors (2):
Bogumił Kamiński Bogumił Kamiński
Profile icon Bogumił Kamiński
Przemysław Szufel Przemysław Szufel
Profile icon Przemysław Szufel
View More author details
Toc

Table of Contents (18) Chapters close

Title Page
Copyright and Credits
Dedication
About Packt
Contributors
Preface
1. Installing and Setting Up Julia 2. Data Structures and Algorithms 3. Data Engineering in Julia 4. Numerical Computing with Julia 5. Variables, Types, and Functions 6. Metaprogramming and Advanced Typing 7. Handling Analytical Data 8. Julia Workflow 9. Data Science 10. Distributed Computing 1. Other Books You May Enjoy Index

Julia IDEs


Integrated Desktop Environments (IDEs) are integrated tools that provide a complete environment for software development and testing. IDEs provide visual support for the development process, including syntax highlighting, interactive code editing, and visual debugging.

Getting ready

Before installing an IDE, you should have Julia installed (either from binaries or source), following the instructions given in previous recipes.

Note

In the GitHub repository for this recipe, you will find the SublimeText.txt file that contains configuration for Sublime Text described in this recipe. The configuration process of other IDEs described in this recipe is completely done with a point and click interface.

How to do it...

The three most popular Julia IDEs are Juno, Microsoft Visual Studio Code, and Sublime Text. In subsequent sections, we discuss the installation process for each particular IDE. 

Juno

Juno is the recommended IDE for Julia development.The Juno IDE is available athttp://junolab.org/. However, Juno runs as a plugin to Atom (https://atom.io/). Hence, in order to install Juno, you need to take the following steps:

  1. Make sure that you have installed Julia and added it to the command path (following the instructions given in previous sections).
  2. Download and install Atom, available athttps://atom.io/.
  3. Once the installation is complete, Atom will start automatically.
  4. PressCtrl + , (Ctrl key + comma key) to open the Atom settings screen.
  5. Select theInstalltab.
  6. In theSearch packagesfield, typeuber-junoand pressEnter.
  7. You will see theuber-junopackage developed by JunoLab—clickInstallto install the package.
  8. In order to test your installation, click theShow consoletab on the left.

 

Please note that when being run for the first time from Atom, Julia takes longer to start. This happens because Juno is installed along with several other packages that are being compiled before their first use. 

Microsoft Visual Studio Code

Note that at the time of publishing this book the Microsoft Visual Studio Code does not yet support Julia 1.0. However, since we believe that this support will be available very soon, we provide the instructions below.

The Microsoft Visual Studio Code editor can be obtained fromhttps://code.visualstudio.com/.Simply download the installer executable and install using the default settings. After launching Visual Studio Code, perform the following steps:

 

  1. ClickExtensionstab (or press Ctrl + Shift + X).

  2. In the search box, typejulia. You will see Julia Language Support on the list. Click the green Install button to start the installation.

  3. Click File | New File to create a new, empty file.

  4. Click File | Save As... to save the newly created file. In the Save As... type drop-down list, select Julia(please note that the file type list might not be sorted alphabetically and Julia type might be at the bottom of the list).

  5. Open the Terminal tab and issue thejuliacommand.

After following these steps, you will have a Julia file open in the editor and an active Julia Terminal. PressingCtrl + Enter will now send the currently highlighted code line to the Terminal to execute it.

Sublime Text

Another option for the IDE is utilizing the functionality of Sublime Text:

  1. If you are using Sublime Text, then add the package namedJuliathroughPackage Control.
  1. Next, the simplest thing to add is a custom build system for Julia (Tools | Build System | New Build System):
{
    "cmd": ["ConEmu64", "/cmd", "julia -i", "$file"],
    "selector": "source.julia"
}
  1. Now, you can execute an opened Julia script by pressingCtrlB in the console in interactive mode (-iswitch).

The preceding example assumes thatConEmu64andjuliaare defined in the search path. 

The only inconvenience of this method is that if there is an error in the Julia script, the console will be immediately terminated (a cleaner way to test your scripts is to keep your Terminal with Julia open) and use theinclude command, as explained in the recipe Useful options for interaction with Julia in this chapter. 

See also

For integration with other editors and IDEs, take a look at the https://github.com/JuliaEditorSupport project.

You have been reading a chapter from
Julia 1.0 Programming Cookbook
Published in: Nov 2018 Publisher: Packt ISBN-13: 9781788998369
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime}