3

Amazingly, I can't find a straight answer to this. This page How to upgrade Julia to a new release? answered the question of upgrading Julia back in 2015, and linked to this page https://github.com/staticfloat/homebrew-julia#upgrading-julia for Mac OS, but (a) the latter page starts with a big "This tap is not actively maintained" warning, and (b) the upgrade instructions only say how to get "the latest development version", which is not what I want (I want Julia 0.7, not 1.0).

So, how do I upgrade Julia from 0.6 to 0.7 on Mac OS X? I installed Julia 0.6 using the command "brew cask install julia".

Peter B
  • 453
  • 4
  • 15
  • Are you looking for a fresh install, or an actual *upgrade*? AFAIK Julia does not offer a method to upgrade v0.6 to v0.7 (I would venture the change to the new `Pkg` would make this incredibly difficult to do). For a fresh install the official binaries (including OS X) are [here](https://julialang.org/downloads/) – Colin T Bowers Aug 13 '18 at 00:24
  • I wasn't aware there was a difference between an upgrade and a fresh install :). I currently run 0.6, I want to run 0.7; I don't care about the details. The julia downloads page doesn't have enough information, at least not for me. – Peter B Aug 13 '18 at 00:33
  • I'm beginning to think this isn't possible with brew: brew appears to only have 1.0 available. I'll take an install of / upgrade to 1.0, so long as I don't lose 0.6. I think "brew cask upgrade julia" will do that? – Peter B Aug 13 '18 at 01:04
  • Answer: no it doesn't :( Brew kept the 0.6 dmg file but blew away (or hid very well) my julia 0.6 binaries – Peter B Aug 13 '18 at 01:16
  • Just download julia 0.7 for mac from the download page and install that. On mac, different versions of julia can work at the same time without affecting each other. You can then either open different versions of julia from your application folder, or call different julia from terminal by using the absolute path. For example, I have julia versions 0.6, 0.7, 1.0 on my mac, and there is no problem with that. – Consistency Aug 13 '18 at 03:09
  • How did you install? Did you use Brew? Brew doesn't seem to allow concurrent different versions. – Peter B Aug 13 '18 at 05:30
  • I'm on Ubuntu, but my understanding of the OS X install process is that you should just be able to download the .dmg file, extract it to any location on your hard-drive, eg maybe a folder called juliav07, and run it from there like any other app. You shouldn't need Brew at all. You might also do well to ask this at the [discourse page](https://discourse.julialang.org/) if you're still having trouble. There are a lot of Mac users there. – Colin T Bowers Aug 13 '18 at 06:08
  • Brew will make the installation process (and also the management) a little complicated. I recommend just downloading the dmg package provided on the download page of julia official website, and then just double click it and move it into your application folder like any other mac application. And by this way, you can have different versions of julia at the same time. You may also create symbolic link or edit path to make one julia version default. And in your case, since you already have brew-installed julia, I think it's better to uninstall it. – Consistency Aug 13 '18 at 14:43

1 Answers1

6

Since nobody answered your question, I shall do it even thought I am not a good writer.

First uninstall julia from home-brew using "brew uninstall julia"

Next go to the julia website and grab the julia dmg for Mac

https://julialang.org/downloads/

Because you can install multiple version of julia at the same time, I suggest you install the following versions

  1. julia 1.0
  2. julia 0.7
  3. julia 0.6

My suggestion is that you install julia 0.6 first by downloading the dmg file. Then double click on it (the dmg file) on the "/user/yourname/Download" directory. Drag the julia to the Application folder (just like how you would install any mac application). Don't forget to eject the dmg image after you have done with it.

Do the same for julia 0.7

Do the same for julia 1.0

Next you need to open the Terminal and create 4 symbolic links. See the commands below and do not type in the "$" character, it is just the command prompt.

$ cd /usr/local/bin
$ ln -s /Applications/Julia-1.0.app/Contents/Resources/julia/bin/julia julia
$ ln -s /Applications/Julia-0.6.app/Contents/Resources/julia/bin/julia julia06
$ ln -s /Applications/Julia-0.7.app/Contents/Resources/julia/bin/julia julia07
$ ln -s /Applications/Julia-1.0.app/Contents/Resources/julia/bin/julia julia10

Now you have 4 different commands you can use

julia
julia06
julia07
julia10

Now you can close the terminal. All done.

Steven Siew
  • 843
  • 8
  • 11