49
49
installkernel(name::AbstractString, options::AbstractString...;
50
50
julia::Cmd,
51
51
specname::AbstractString,
52
- env=Dict())
52
+ fuzzy_completion_mode::Bool=false
53
+ env::Dict{<:AbstractString}=Dict())
53
54
54
55
Install a new Julia kernel, where the given `options` are passed to the `julia`
55
56
executable, the user-visible kernel name is given by `name` followed by the
56
57
Julia version, and the `env` dictionary is added to the environment.
58
+ If `fuzzy_completion_mode` is `true`, then <kbd>shift-tab</kbd> completions will be done fuzzily.
57
59
58
60
The new kernel name is returned by `installkernel`. For example:
59
61
```
@@ -85,7 +87,9 @@ installkernel(
85
87
function installkernel (name:: AbstractString , julia_options:: AbstractString... ;
86
88
julia:: Cmd = ` $(joinpath (Sys. BINDIR,exe (" julia" ))) ` ,
87
89
specname:: AbstractString = replace (lowercase (name), " " => " -" ),
88
- env:: Dict{<:AbstractString} = Dict {String,Any} ())
90
+ fuzzy_completion_mode:: Bool = false ,
91
+ env:: Dict{<:AbstractString} = Dict {String,Any} (),
92
+ )
89
93
# Is IJulia being built from a debug build? If so, add "debug" to the description.
90
94
debugdesc = ccall (:jl_is_debugbuild ,Cint,())== 1 ? " -debug" : " "
91
95
@@ -100,6 +104,8 @@ function installkernel(name::AbstractString, julia_options::AbstractString...;
100
104
ijulia_dir = get (ENV , " IJULIA_DIR" , dirname (@__DIR__ )) # support non-Pkg IJulia installs
101
105
append! (kernelcmd_array, [joinpath (ijulia_dir," src" ," kernel.jl" ), " {connection_file}" ])
102
106
107
+ push! (env, " IJULIA_COMPLETION_MODE" => fuzzy_completion_mode ? " fuzzy" : " repl" )
108
+
103
109
ks = Dict (
104
110
" argv" => kernelcmd_array,
105
111
" display_name" => name * " " * Base. VERSION_STRING * debugdesc,
0 commit comments