reujab / silver

A cross-shell customizable powerline-like prompt with icons

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

TOML config

thecaralice opened this issue · comments

Use TOML for config instead of environment variables, this would allow more flexible setups. Maybe this will also deprecate $SILVER_SHELL, see #42. $SILVER_SHELL is already removed.

Example config

icon_set = "nerd"
[icons]
failed = "\u2717"

[separator.left]
thick = "\ue0b4"
thin = "\ue0b5"

[separator.right]
thick = "\ue0b6"
thin = "\ue0b7"

[[left]]
name = "dir"
color.background = "blue"
color.foreground = "black"

[[left]]
name = "git"
color.background = "green"
color.foreground = "black"
args = ["red"]

[[right]]
name = "status"
color.foreground = "white"
color.background = "black"

[[right]]
name = "cmdtime"
color.background = "magenta"
color.foreground = "black"

[[right]]
name = "shell"
color.background = "green"
color.foreground = "black"

In fish it would be

set -x SILVER_LEFT_SEPARATOR \ue0b4
set -x SILVER_THIN_LEFT_SEPARATOR \ue0b5
set -x SILVER_RIGHT_SEPARATOR \ue0b6
set -x SILVER_THIN_RIGHT_SEPARATOR \ue0b7
set -x SILVER_ICON_FAILED \u2717
set -x SILVER_ICONS nerd
set SILVER_LEFT dir:blue:black git:green:black:red 
set SILVER_RIGHT status:black:white cmdtime:magenta:black shell:green:black

I like this idea.

Added config example