-
-
Save meramsey/95e6e50f3ac7e2e57f34919d87951104 to your computer and use it in GitHub Desktop.
Starship prompt Left+Right and config for xonsh shell
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Save to ~/.xonshrc | |
# https://github.com/anki-code/xontrib-prompt-starship | |
# Below is example to put in xonsh config ~/.xonshrc for xontrib-prompt-starship | |
#$STARSHIP_CONFIG = "~/.config/starship_xonsh.toml" | |
$XONTRIB_PROMPT_STARSHIP_LEFT_CONFIG = "~/.config/starship_xonsh_left.toml" | |
#$XONTRIB_PROMPT_STARSHIP_RIGHT_CONFIG = "~/.config/starship_xonsh_right.toml" | |
#$XONTRIB_PROMPT_STARSHIP_BOTTOM_CONFIG = "~/.config/starship_xonsh_bottom.toml" | |
xontrib load prompt_starship |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# https://starship.rs/config/#prompt | |
add_newline = false # Disable the blank line at the start of the prompt | |
scan_timeout = 30 # Timeout for starship to scan files (in milliseconds). | |
# Use custom format | |
# with multiline basic string | |
format = """ | |
$username\ | |
$hostname\ | |
$shlvl\ | |
$directory\ | |
$git_branch\ | |
$git_state\ | |
$git_status\ | |
$status\ | |
$cmd_duration\ | |
$memory_usage\ | |
$jobs\ | |
$battery\ | |
$time | |
$line_break\ | |
$character""" | |
# https://starship.rs/config/#line-break | |
[line_break] | |
disabled = false | |
# https://starship.rs/config/#username | |
[username] | |
style_user = "blue bold" | |
style_root = "black bold" | |
format = "[$user]($style)" | |
disabled = false | |
show_always = false | |
# https://starship.rs/config/#hostname | |
[hostname] | |
ssh_only = true | |
format = "[[@](bold black)$hostname]($style) " | |
style = "dimmed purple" | |
trim_at = "." | |
disabled = false | |
# https://starship.rs/config/#directory | |
[directory] | |
truncate_to_repo = false | |
use_logical_path = true | |
# https://starship.rs/config/#character | |
# Replace the "❯" symbol in the prompt with "@" | |
[character] | |
format = "$symbol " | |
success_symbol = "[@](bold green)" | |
error_symbol = "[@](bold red)" | |
# https://starship.rs/config/#status | |
[status] | |
style = "bg:red" | |
symbol = "✖" | |
format = '[\[$symbol $common_meaning$signal_name$maybe_int\]]($style) ' | |
map_symbol = true | |
disabled = false | |
# https://starship.rs/config/#shell | |
# [shell] | |
# fish_indicator = "" | |
# powershell_indicator = "_" | |
# unknown_indicator = "mystery shell" | |
# disabled = false | |
# https://starship.rs/config/#git-status | |
[git_status] | |
# format = '([$all_status$ahead_behind]($style)[](fg:236))' | |
style = "bold white bg:236" | |
conflicted = " 🏳$count" | |
ahead = " ⇡$count" | |
behind = " ⇣$count" | |
diverged = " [$ahead_count](green)⇕[$behind_count](red bg:236)" | |
untracked = " [$count🤷](purple bg:236)" | |
stashed = " [$count⚑](green bg:236)" | |
modified = " [$count📝](yellow bg:236)" | |
staged = " [$count●](green bg:236)" | |
renamed = " [$count👅](yellow bg:236)" | |
deleted = " [$count🗑](red bg:236)" | |
disabled = false | |
# https://starship.rs/config/#command-duration | |
[cmd_duration] | |
format = " took [$duration ]($style) " | |
min_time = 2_000 | |
style = "bold green" | |
show_notifications = true | |
# https://starship.rs/config/#time | |
[time] | |
disabled = false | |
#format = "at [$time 🕙] " | |
#time_format = "%T" | |
#format = '🕙[\[ $time \]]($style) ' | |
# https://starship.rs/config/#memory-usage | |
[memory_usage] | |
disabled = false | |
threshold = 75 | |
symbol = " " | |
format = "$symbol [${ram}]($style) " | |
style = "bold dimmed green" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Save to ~/.config/starship_xonsh_left.toml if using | |
# and uncomment desired lines in this file | |
# and the uncomment/add the line in > $XONTRIB_PROMPT_STARSHIP_RIGHT_CONFIG = "~/.config/starship_xonsh_right.toml" | |
# https://starship.rs/config/#prompt | |
# add_newline = false # Disable the blank line at the start of the prompt | |
# scan_timeout = 30 # 30 # Timeout for starship to scan files (in milliseconds). | |
# format = """ | |
# $character\ | |
# $cmd_duration\ | |
# $memory_usage\ | |
# $jobs\ | |
# $battery\ | |
# $time""" | |
# https://starship.rs/config/#git-status | |
# [git_status] | |
# # format = '([$all_status$ahead_behind]($style)[](fg:236))' | |
# style = "bold white bg:236" | |
# conflicted = " =$count" | |
# ahead = " ⇡$count" | |
# behind = " ⇣$count" | |
# diverged = " [$ahead_count](green)⇕[$behind_count](red bg:236)" | |
# untracked = " [$count🤷](purple bg:236)" | |
# stashed = " $count📦" | |
# modified = " [$count📝](yellow bg:236)" | |
# staged = " +$count" | |
# renamed = " »$count" | |
# deleted = " [$count🗑](red bg:236)" | |
# disabled = false | |
# https://starship.rs/config/#line-break | |
# [line_break] | |
# disabled = false | |
# https://starship.rs/config/#command-duration | |
# [cmd_duration] | |
# format = "⏲ took [$duration]($style) " | |
# min_time = 2_000 | |
# style = "bold green" | |
# show_notifications = true | |
# https://starship.rs/config/#time | |
# [time] | |
# disabled = false | |
#format = "at [$time 🕙] " | |
#time_format = "%T" | |
#format = '🕙[\[ $time \]]($style) ' | |
# old | |
# format = "at [$time]🕙 " | |
# time_format = "%T" | |
# utc_time_offset = "-5" | |
# time_range = "00:00:00-23:59:59" | |
# https://starship.rs/config/#memory-usage | |
# [memory_usage] | |
# disabled = false | |
# threshold = -1 | |
# symbol = " " | |
# format = " $symbol [${ram}]($style) " | |
# style = "bold dimmed green" | |
# https://starship.rs/config/#python | |
# [python] | |
# disabled = true | |
# https://starship.rs/config/#package-version | |
# Disable the package module, hiding it from the prompt completely | |
# [package] | |
# disabled = true | |
# https://starship.rs/config/#character | |
# [character] | |
# success_symbol = "[✔](bold green) " | |
# error_symbol = "[✗](bold red) " |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment