findJulia {XRJulia} | R Documentation |
Find a Julia Executable
Description
This function looks for an executable Julia application in the local operating system. The location can be prespecified by
setting environment variable JULIA_BIN
; otherwise, the function looks in various conventional locations
and if that doesn't work, runs a shell command to look for julia
.
Usage
findJulia(test = FALSE)
Arguments
test |
Should the function test for the existence of the application. Default |
Value
The location as a character string, unless test
is TRUE
, in which case success or failure
is returned, and the location found (or the empty string) is saved as the environment variable.
Note that in this case, FALSE
is returned if the Julia package JSON
has not been added.
If test
is FALSE
, failure to find a Julia
in the current system is an error.
On Mac OS X
Installing Julia in the usual way does not put the command line version in a
standard location, but instead in a folder under /Applications
.
Assuming one wants to have Julia available from the command line,
creating a symbolic link to it in /usr/local/bin
is a standard approach.
If the current version of Julia is 0.6
:
sudo ln -s /Applications/Julia-0.6.app/Contents/Resources/julia/bin/julia /usr/local/bin/julia
If for some reason you did not want this to be available, set the shell variable
JULIA_BIN
to the first file in the command, the one in /Applications
.