Skip to content

Commit

Permalink
fix: show full path for file completions
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Nov 12, 2024
1 parent 1a113d9 commit eb18a91
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions cli/src/cli/complete_word.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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()
Expand Down
2 changes: 1 addition & 1 deletion mise.lock
Original file line number Diff line number Diff line change
@@ -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"
Expand Down

0 comments on commit eb18a91

Please sign in to comment.