|
@ -17,13 +17,13 @@ impl PromptStyle { |
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
fn fmt_none(&self) -> String {
|
|
|
fn fmt_none(&self) -> String {
|
|
|
return "» ".to_string();
|
|
|
|
|
|
|
|
|
"» ".to_string()
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
fn fmt_simple_directory(&self) -> String {
|
|
|
fn fmt_simple_directory(&self) -> String {
|
|
|
let path = env::current_dir().unwrap_or_default();
|
|
|
let path = env::current_dir().unwrap_or_default();
|
|
|
|
|
|
|
|
|
return format!("{} » ", path.to_string_lossy());
|
|
|
|
|
|
|
|
|
format!("{} » ", path.to_string_lossy())
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|
fn fmt_bash_like(&self) -> String {
|
|
|
fn fmt_bash_like(&self) -> String {
|
|
@ -43,7 +43,7 @@ impl PromptStyle { |
|
|
let _hostname = gethostname::gethostname();
|
|
|
let _hostname = gethostname::gethostname();
|
|
|
let hostname = _hostname.to_string_lossy();
|
|
|
let hostname = _hostname.to_string_lossy();
|
|
|
|
|
|
|
|
|
return format!("[{}@{} {}]$ ", username, hostname, dir_as_string);
|
|
|
|
|
|
|
|
|
format!("[{}@{} {}]$ ", username, hostname, dir_as_string)
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
|
|
|