Skip to content

Commit

Permalink
add current profile indicator
Browse files Browse the repository at this point in the history
  • Loading branch information
qimiko committed Mar 20, 2023
1 parent 05f3aaf commit adee551
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/profile.rs
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,15 @@ pub fn subcommand(config: &mut Config, cmd: Profile) {
let name = &profile.borrow().name;
let path = &profile.borrow().gd_path;

let indicator = if config.current_profile.as_ref() == Some(name) {
"* "
} else {
""
};

println!(
"{} [ path = {} ]",
"{}{} [ path = {} ]",
indicator.bright_cyan(),
name.bright_cyan(),
path.to_string_lossy().bright_green()
);
Expand Down

0 comments on commit adee551

Please sign in to comment.