fixed errors

This commit is contained in:
Candifloss 2024-08-17 16:48:19 +05:30
parent 927aeec3ba
commit 69ea3213a5

View File

@ -25,7 +25,7 @@ fn get_shell_char (shell: String) -> String {
}
fn get_git_char (git_branch: String) -> ColoredString {
match get_git_char.as_str() {
match git_branch.as_str() {
"main" => " 󰊢 ".truecolor(178,98,44),
"master" => " 󰊢 ".truecolor(196,132,29),
_ => " 󰊢 ".truecolor(82,82,82),
@ -104,11 +104,8 @@ fn main() -> std::io::Result<()> {
.split(" ").collect::<Vec<&str>>()[2]
.truecolor(82,82,82);
git_char = match git_branch.to_string().as_str() {
"main" => " 󰊢 ".truecolor(178,98,44),
"master" => " 󰊢 ".truecolor(196,132,29),
_ => " 󰊢 ".truecolor(82,82,82),
};
git_char = get_git_char(git_branch.to_string());
let git_repo_root_cmd = Command::new("git")
.arg("rev-parse")
.arg("--show-toplevel")