Show relative path by default instead of absolute

The absolute path is long and doesn't really provide much information.
  Plus, it's inconsistent with the behavior on a specified path.
This commit is contained in:
KtorZ
2024-09-07 18:24:46 +02:00
parent 943d90a99e
commit 28916c1ef9

View File

@@ -94,8 +94,12 @@ where
{
let project_path = if let Some(d) = directory {
d.to_path_buf()
} else {
} else if std::env::consts::OS == "windows" {
env::current_dir().into_diagnostic()?
} else {
let mut current_dir = std::path::PathBuf::new();
current_dir.push(".");
current_dir
};
let mut project = match Project::new(project_path, Terminal) {