nixos/home/dotfiles/prompt.json
2024-09-29 19:28:08 -04:00

81 lines
2.2 KiB
JSON

{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"palette": {
"nix": "#81A1C1",
"error": "#BF616A",
"backgroundish": "#525252",
"white": "#FFF",
"whiteish": "#DDE1E6"
},
"blocks": [
{
"alignment": "left",
"segments": [
{
"foreground": "p:whiteish",
"properties": {
"folder_separator_icon": "/",
"home_icon": "~",
"style": "letter"
},
"style": "plain",
"template": "{{.Path}} ",
"type": "path"
},
{
"foreground": "p:whiteish",
"properties": {
"branch_icon": "",
"branch_ahead_icon": "\u21e1",
"branch_behind_icon": "\u21e3",
"fetch_stash_count": true,
"fetch_status": true,
"fetch_upstream_icon": true,
"github_icon": ""
},
"style": "plain",
"template": "<p:backgroundish>on </>{{.HEAD}}<p:backgroundish></> ",
"type": "git"
},
{
"foreground": "p:white",
"foreground_templates": [
"{{if contains .Env.IN_NIX_SHELL \"pure\"}}p:nix{{end}}",
"{{if contains .Env.IN_NIX_SHELL \"impure\"}}p:nix{{end}}",
"{{if gt .Code 0}}p:error{{end}}"
],
"style": "plain",
"template": "<b>{{if .Root}}#{{else}}λ{{end}}</b> ",
"type": "text"
}
],
"type": "prompt"
},
{
"alignment": "left",
"segments": [
{
"type": "executiontime",
"style": "plain",
"template": "<#eed49f>{{ .FormattedMs }}</>"
}
],
"type": "rprompt"
}
],
"console_title_template": "{{if .Root}}#{{end}} {{.PWD}}",
"transient_prompt": {
"foreground": "p:white",
"foreground_templates": [
"{{if contains .Env.IN_NIX_SHELL \"pure\"}}p:nix{{end}}",
"{{if contains .Env.IN_NIX_SHELL \"impure\"}}p:nix{{end}}",
"{{if gt .Code 0 }}p:error{{ end }}"
],
"template": "<b>λ</b> "
},
"secondary_prompt": {
"foreground": "p:backgroundish",
"template": "<b>λ></b> "
},
"version": 2
}