context menu with nucompleter (#722)

This commit is contained in:
Fernando Herrera 2022-01-11 21:53:42 +00:00 committed by GitHub
parent ffb086d56f
commit 47495715a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 3 deletions

2
Cargo.lock generated
View File

@ -2777,7 +2777,7 @@ dependencies = [
[[package]] [[package]]
name = "reedline" name = "reedline"
version = "0.2.0" version = "0.2.0"
source = "git+https://github.com/nushell/reedline?branch=main#af19a7bfc69ff44b08673fd17a587b0be4f879a6" source = "git+https://github.com/nushell/reedline?branch=main#2cb2e40195b86145dd90779f4015dc834a62b720"
dependencies = [ dependencies = [
"chrono", "chrono",
"crossterm", "crossterm",

View File

@ -403,7 +403,8 @@ fn main() -> Result<()> {
engine_state: engine_state.clone(), engine_state: engine_state.clone(),
})) }))
.with_edit_mode(edit_mode) .with_edit_mode(edit_mode)
.with_ansi_colors(config.use_ansi_coloring); .with_ansi_colors(config.use_ansi_coloring)
.with_menu_completer(Box::new(NuCompleter::new(engine_state.clone())));
//FIXME: if config.use_ansi_coloring is false then we should //FIXME: if config.use_ansi_coloring is false then we should
// turn off the hinter but I don't see any way to do that yet. // turn off the hinter but I don't see any way to do that yet.