diff --git a/base/client.jl b/base/client.jl index 88d6f871079e0..093b53fc362ce 100644 --- a/base/client.jl +++ b/base/client.jl @@ -306,7 +306,9 @@ let reqarg = Set(UTF8String["--home", "-H", repl = false # remove filename from ARGS shift!(ARGS) - ccall(:jl_exit_on_sigint, Void, (Cint,), 1) + if !is_interactive + ccall(:jl_exit_on_sigint, Void, (Cint,), 1) + end include(args[1]) else println(STDERR, "julia: unknown option `$(args[1])`") @@ -315,6 +317,7 @@ let reqarg = Set(UTF8String["--home", "-H", end break end + repl |= is_interactive return (quiet,repl,startup,color_set,history_file) end end diff --git a/ui/repl.c b/ui/repl.c index c756ef6c6932f..4b01348a06825 100644 --- a/ui/repl.c +++ b/ui/repl.c @@ -61,7 +61,7 @@ static const char opts[] = " 'auto' launches as many workers as the number of local cores\n" " --machinefile Run processes on hosts listed in \n\n" - " -i Force isinteractive() to be true\n" + " -i Interactive mode; REPL runs and isinteractive() is true\n" " --color={yes|no} Enable or disable color text\n\n" " --history-file={yes|no} Load or save history\n" " --no-history-file Don't load history file (deprecated, use --history-file=no)\n" @@ -76,8 +76,7 @@ static const char opts[] = " --track-allocation={none|user|all}, --track-allocation\n" " Count bytes allocated by each source line\n\n" - " -O, --optimize\n" - " Run time-intensive code optimizations\n" + " -O, --optimize Run time-intensive code optimizations\n" " --check-bounds={yes|no} Emit bounds checks always or never (ignoring declarations)\n" " --dump-bitcode={yes|no} Dump bitcode for the system image (used with --build)\n" " --depwarn={yes|no} Enable or disable syntax and method deprecation warnings\n"