From eb18a91bb0e2245d1946ab89cdb9316da54d76f8 Mon Sep 17 00:00:00 2001 From: jdx <216188+jdx@users.noreply.github.com> Date: Tue, 12 Nov 2024 06:24:09 -0600 Subject: [PATCH] fix: show full path for file completions --- cli/src/cli/complete_word.rs | 4 ++-- mise.lock | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/cli/src/cli/complete_word.rs b/cli/src/cli/complete_word.rs index b287e1a..75dd08d 100644 --- a/cli/src/cli/complete_word.rs +++ b/cli/src/cli/complete_word.rs @@ -172,9 +172,9 @@ impl CompleteWord { fn complete_builtin(&self, type_: &str, ctoken: &str) -> Vec<(String, String)> { let names = match (type_, env::current_dir()) { - ("path", Ok(cwd)) => self.complete_path(&cwd, ctoken, |_| true), + ("path" | "file", Ok(cwd)) => self.complete_path(&cwd, ctoken, |_| true), ("dir", Ok(cwd)) => self.complete_path(&cwd, ctoken, |p| p.is_dir()), - ("file", Ok(cwd)) => self.complete_path(&cwd, ctoken, |p| p.is_file()), + // ("file", Ok(cwd)) => self.complete_path(&cwd, ctoken, |p| p.is_file()), _ => vec![], }; names.into_iter().map(|n| (n, String::new())).collect() diff --git a/mise.lock b/mise.lock index a349fcf..b055224 100644 --- a/mise.lock +++ b/mise.lock @@ -1,5 +1,5 @@ [tools] -actionlint = "1.7.3" +actionlint = "1.7.4" cargo-binstall = "1.10.8" "cargo:cargo-edit" = "0.13.0" "cargo:cargo-insta" = "1.41.1"