thank you, it works by adding “-i”. But I am curious what is the propose of “-i”, it looks like force julia go to the REPL, because after I ran above commend, it jumped into the REPL. I am wondering could I stay in my previous environment. Thanks
for the display window to stay open, the Julia process can’t exit. You can also put a readline() after the display() but you still won’t be able to use that terminal session.
-i puts you into interactive mode (REPL) after executing the script, which is a way to prevent exiting
On the phone so haven’t tried, but I believe you can also call wait on the return from display to wait until the window decides it is done. E.g. wait(display(fig))