Tab inline completion (#6802)

* Make Tab insert (partial) completion instead of select next menu item

* Use reedline feature branch

Co-authored-by: JT <547158+jntrnr@users.noreply.github.com>
This commit is contained in:
Dan Davison
2022-10-20 06:39:48 -04:00
committed by GitHub
parent 5e748ae8fc
commit 5eee33c7e4
5 changed files with 5 additions and 6 deletions

View File

@ -20,7 +20,7 @@ nu-protocol = { path = "../nu-protocol", version = "0.70.1" }
nu-utils = { path = "../nu-utils", version = "0.70.1" }
nu-ansi-term = "0.46.0"
nu-color-config = { path = "../nu-color-config", version = "0.70.1" }
reedline = { version = "0.13.0", features = ["bashisms", "sqlite"]}
reedline = { git = "https://github.com/dandavison/reedline.git", branch="tab-inline-completion", features = ["bashisms", "sqlite"]}
atty = "0.2.14"
chrono = "0.4.21"

View File

@ -491,7 +491,7 @@ fn add_menu_keybindings(keybindings: &mut Keybindings) {
KeyCode::Tab,
ReedlineEvent::UntilFound(vec![
ReedlineEvent::Menu("completion_menu".to_string()),
ReedlineEvent::MenuNext,
ReedlineEvent::Edit(vec![EditCommand::Complete]),
]),
);

View File

@ -88,7 +88,7 @@ unicode-segmentation = "1.8.0"
url = "2.2.1"
uuid = { version = "1.1.2", features = ["v4"] }
which = { version = "4.3.0", optional = true }
reedline = { version = "0.13.0", features = ["bashisms", "sqlite"]}
reedline = { git = "https://github.com/dandavison/reedline.git", branch="tab-inline-completion", features = ["bashisms", "sqlite"]}
wax = { version = "0.5.0", features = ["diagnostics"] }
rusqlite = { version = "0.28.0", features = ["bundled"], optional = true }
sqlparser = { version = "0.23.0", features = ["serde"], optional = true }