Search code examples
juliajupyter-notebookijulia-notebook

Opening a specific Julia notebook (via IJulia) in the REPL


the Julia (i'm using 0.6.2) REPL makes it possible to do some work and then execute

julia> using IJulia
julia> notebook(dir=pwd(), detached=true)

which nicely launches jupyter in the directory specified by dir.

is it possible from the REPL to include a specific notebook to open ?


Solution

  • This worked for me recently (julia v 1.5.1, macOS 10.14):

    using IJulia
    notebook(dir="/path/to/directory/with/my/notebook",detached=true)
    

    One thing I noticed is starting jupyter in the background, julia doesn't give you a link to where to open the notebook in the browser.

    I was able to open http://localhost:8888/ in my browser to find the notebook, although I thought there was a URL token needed. This link in the browser also worked:

    file:///$HOME/Library/Jupyter/runtime/nbserver-12912-open.html
    

    I got this from the REPL documentation:

    ?notebook
    
    #search: notebook
    
    #  notebook(; dir=homedir(), detached=false)
    # ..etc