Files
dotfiles/theme.omp.json
2024-10-14 20:39:34 +11:00

95 lines
3.0 KiB
JSON

{
"$schema": "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json",
"version": 2,
"blocks": [
{
"type": "prompt",
"alignment": "left",
"segments": [
{
"type": "session",
"style": "plain",
"foreground": "lightBlue",
"foreground_templates": [
"{{ if .Root }}lightRed{{ end }}"
],
"template": "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>\u250c\u2500\u2500(</>{{ .UserName }}{{ if .Root }}💀{{ else }}@{{ end }}{{ .HostName }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>)</>",
"properties": {
"display_host": true
}
},
{
"type": "python",
"style": "plain",
"foreground": "yellow",
"template": "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</> {{ if .Error }}{{ .Error }}{{ else }}{{ if .Venv }}{{ .Venv }} {{ end }}(v{{ .Full }}){{ end }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>",
"properties": {
"fetch_version": true,
"fetch_virtual_env": true,
"display_version": true,
"display_mode": "context"
}
},
{
"type": "path",
"style": "plain",
"foreground": "lightWhite",
"template": "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</>{{ .Path }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>",
"properties": {
"folder_separator_icon": "<#c0c0c0>/</>",
"style": "full"
}
},
{
"type": "git",
"style": "plain",
"foreground": "white",
"template": "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>-[</>{{ .HEAD }}<{{ if .Root }}lightBlue{{ else }}green{{ end }}>]</>"
}
]
},
{
"type": "prompt",
"alignment": "right",
"segments": [
{
"type": "executiontime",
"style": "plain",
"foreground": "white",
"template": " {{ .FormattedMs }} ",
"properties": {
"always_enabled": false,
"threshold": 50,
"style": "round"
}
},
{
"type": "executiontime",
"style": "plain",
"foreground": "green",
"foreground_templates": [
"{{ if gt .Code 0 }}red{{ end }}"
],
"template": " {{ if gt .Code 0 }}\u2a2f{{else}}✓{{ end }} ",
"properties": {
"always_enabled": false,
"threshold": 50
}
}
]
},
{
"type": "prompt",
"alignment": "left",
"segments": [
{
"type": "text",
"style": "plain",
"foreground": "lightBlue",
"template": "<{{ if .Root }}lightBlue{{ else }}green{{ end }}>\u2514\u2500</>{{ if .Root }}<lightRed>#</>{{ else }}${{ end }} "
}
],
"newline": true
}
]
}