diff --git a/bash/.config/bash/prompt.sh b/bash/.config/bash/prompt.sh index 565795f..16e1b45 100644 --- a/bash/.config/bash/prompt.sh +++ b/bash/.config/bash/prompt.sh @@ -1,5 +1,9 @@ #!/usr/bin/env bash +if [[ -z ${STARSHIP_SESSION_KEY} ]] ; then + return +fi + # Reset color_off='\e[0m' # Text Reset diff --git a/starship/.config/bash/bashrc.d/starship.sh b/starship/.config/bash/bashrc.d/starship.sh new file mode 100644 index 0000000..b6ee6e8 --- /dev/null +++ b/starship/.config/bash/bashrc.d/starship.sh @@ -0,0 +1 @@ +eval "$(starship init bash)" diff --git a/starship/.config/starship.toml b/starship/.config/starship.toml new file mode 100644 index 0000000..2e01abf --- /dev/null +++ b/starship/.config/starship.toml @@ -0,0 +1,51 @@ +format = """\ + $username\ + $hostname\ + $directory\ + $git_branch\ + $git_commit\ + $git_state\ + $git_status\ + $time\ + $cmd_duration\ + $line_break\ + $character\ +""" + +[username] +disabled = false +show_always = true +style = "green" +style_user = "green" + +[hostname] +disable = false +ssh_only = false +style = "purple" +# format = "[$hostname]($style)" + +[git_branch] +style = "black bold" +symbol = "" +# format = "[$symbol$branch]($style)" + +[directory] +truncation_length = 0 +use_logical_path = true +truncate_to_repo = false +style = "blue" + +[time] +disabled = false +style = "purple" +time_format = "%T" +format = "[$time]($style)" + +[cmd_duration] +# $duration – The command duration (e.g. "15s") +# $style – The default style of the module (e.g. "bold yellow") +format = "took [$duration]($style) " + +[character] +success_symbol = "λ" +style_success = ""