This commit is contained in:
pika 2024-08-17 23:05:37 +02:00
parent da95b0863a
commit 993c1a76f3

View file

@ -1,27 +1,26 @@
"$schema" = "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json" #"$schema" = "https://raw.githubusercontent.com/JanDeDobbeleer/oh-my-posh/main/themes/schema.json"
version = 2 version = 2
final_space = true
[[blocks]] [[blocks]]
newline = true newline = true
alignment = "left" alignment = "left"
type = "prompt" type = "prompt"
[[blocks.segments]] [[blocks.segments]]
foreground = "#45F1C2" foreground = "#45F1C2"
foreground_templates = [
"{{if .Root }}red{{end}}",
]
style = "plain" style = "plain"
template = " {{ .UserName }} " template = " {{ .UserName }}"
type = "session" type = "session"
[[blocks.segments]] [[blocks.segments]]
foreground = "red" foreground = "red"
style = "plain" style = "plain"
template = "@" template = "󰁥 "
type = "text" type = "text"
[[blocks.segments]] [[blocks.segments]]
foreground = "#45F1C2" foreground = "#45F1C2"
style = "plain" style = "plain"
template = " {{ .HostName }} " template = " {{ .HostName }} "
type = "session" type = "session"
[[blocks]] [[blocks]]
@ -31,32 +30,38 @@ type = "prompt"
[[blocks.segments]] [[blocks.segments]]
foreground = "#0CA0D8" foreground = "#0CA0D8"
style = "plain" style = "plain"
template = " {{ .Path }} " template = " {{ .Path }} "
type = "path" type = "path"
[blocks.segments.properties] [blocks.segments.properties]
folder_separator_icon = "/" folder_separator_icon = "/"
style = "full" style = "full"
[[blocks.segments]] [[blocks.segments]]
type = "git" type = "git"
style = "plain" style = "plain"
foreground = "#193549" foreground = "#193549"
background = "transparent" background = "transparent"
template = "{{ .UpstreamIcon }}{{ .HEAD }}{{if .BranchStatus }} {{ .BranchStatus }}{{ end }}{{ if .Working.Changed }} {{ .Working.String }}{{ end }}{{ if and (.Working.Changed) (.Staging.Changed) }} |{{ end }}{{ if .Staging.Changed }} {{ .Staging.String }}{{ end }}{{ if gt .StashCount 0 }} {{ .StashCount }}{{ end }}" foreground_templates = [
[blocks.segments.properties] "{{ if or (.Working.Changed) (.Staging.Changed) }}#a7364d{{else}}#1ea54c{{end}}"
]
template = "{{ .UpstreamIcon }}{{ .HEAD }}{{if .BranchStatus }} {{ .BranchStatus }}{{ end }}{{ if .Working.Changed }}  {{ .Working.String }}{{ end }}{{ if and (.Working.Changed) (.Staging.Changed) }} |{{ end }}{{ if .Staging.Changed }}  {{ .Staging.String }}{{ end }}{{ if gt .StashCount 0 }}  {{ .StashCount }}{{ end }}"
[properties]
fetch_status = true fetch_status = true
fetch_upstream_icon = true fetch_upstream_icon = true
fetch_stash_count = true source = "cli"
[blocks.segments.properties.branch_icon] [properties.mapped_branches]
"feat/*" = "🚀 " "feat/*" = "🚀 "
"bug/*" = "🐛 " "bug/*" = "🐛 "
"main" = "💎 " "main/*" = "💎 "
"dev" = "⚙️ " "dev/*" = "⚙️ "
[blocks.segments.properties.template_logic] # foreground = "#915ada"
default = "#1ea54c" # powerline_symbol = ""
has_staged = "#a7364d" # style = "plain"
has_unstaged = "#a7364d" # # template = "{{ .UpstreamIcon }}{{ .HEAD }}{{ if gt .StashCount 0 }}  {{ .StashCount }}{{ end }} "
# template = ' {{ .HEAD }}{{ if or (.Working.Changed) (.Staging.Changed) }}*{{ end }} <cyan>{{ if gt .Behind 0 }}⇣{{ end }}{{ if gt .Ahead 0 }}⇡{{ end }}</>'
# type = "git"
[blocks.segments.properties]
fetch_stash_count = true
fetch_upstream_icon = true
[[blocks]] [[blocks]]
alignment = "left" alignment = "left"
newline = true newline = true
@ -64,7 +69,7 @@ type = "prompt"
[[blocks.segments]] [[blocks.segments]]
foreground = "#cd5e42" foreground = "#cd5e42"
style = "plain" style = "plain"
template = " " template = " "
type = "root" type = "root"
[[blocks.segments]] [[blocks.segments]]
foreground = "#CD4277" foreground = "#CD4277"
@ -72,12 +77,17 @@ style = "plain"
template = "# " template = "# "
type = "text" type = "text"
[[blocks]]
alignment = "left"
type = "plain"
[transient_prompt] [transient_prompt]
background = "transparent" background = 'transparent'
foreground = "#CD4277" foreground = 'magenta'
template = "{{ if gt .Code 0 }}{{ else }}{{ end }} " template = ""
# template = '>'
[secondary_prompt] type = "prompt"
background = "transparent" foreground_templates = [
foreground = "#CD4277" "{{if gt .Code 0}}red{{end}}",
template = "{{ if gt .Code 0 }}{{ else }}{{ end }} " "{{if eq .Code 0}}green{{end}}",
]
# # foreground = "p:terminal-blue"