[yambar] Improve CPU and temperature display

This commit is contained in:
Midgard 2022-08-30 00:57:59 +02:00
parent e4396a85d6
commit 6fd68a24b3
Signed by untrusted user who does not match committer: midgard
GPG key ID: 511C112F1331BBB4
2 changed files with 42 additions and 30 deletions

Binary file not shown.

View file

@ -124,21 +124,59 @@ bar:
- string: {foreground: *col_fg_caution, text: "RAM {percent_used}%"} # 90-95
- string: {foreground: *col_fg_alert, text: "RAM {percent_used}%"} # 95-100
- cpu:
interval: 5000
content:
list:
spacing: 0
font: *font_supplements
items:
- ramp:
tag: cpu0
items: &cpu_ramp
# 
- empty: {} # 0-6
- empty: {} # 6-12
- empty: {} # 12-18
- empty: {} # 18-25
- empty: {} # 25-31
- empty: {} # 31-37
- empty: {} # 37-43
- empty: {} # 43-50
- empty: {} # 50-56
- empty: {} # 56-62
- string: {margin: 1, text: "", foreground: "88888888" } # 62-68
- string: {margin: 1, text: "", foreground: "888888aa" } # 68-75
- string: {margin: 1, text: "", foreground: "888888cc" } # 75-81
- string: {margin: 1, text: "", foreground: "888888ee" } # 81-87
- string: {margin: 1, text: "", foreground: *col_fg_caution } # 87-93
- string: {margin: 1, text: "", foreground: *col_fg_caution } # 93-100
- ramp: {tag: cpu1, items: *cpu_ramp}
- ramp: {tag: cpu2, items: *cpu_ramp}
- ramp: {tag: cpu3, items: *cpu_ramp}
- ramp: {tag: cpu4, items: *cpu_ramp}
- ramp: {tag: cpu5, items: *cpu_ramp}
- ramp: {tag: cpu6, items: *cpu_ramp}
- ramp: {tag: cpu7, items: *cpu_ramp}
- script:
font: "Fira Mono:size=12"
poll-interval: 5
path: /home/midgard/.config/yambar/temp.sh
content:
map:
tag: status
default: {string: {text: "{temp}°C {rpm} RPM"}}
default:
- string: &str_temp {text: "{temp}°C", font: "Fira Mono:size=12", right-margin: 5}
- string: &str_rpm {text: "{rpm} RPM", font: "Fira Sans:size=12", foreground: *col_fg_alt}
values:
normal:
empty: {}
caution:
string: {text: "{temp}°C {rpm} RPM", foreground: *col_fg_caution}
- string: {<<: *str_temp, foreground: *col_fg_caution}
- string: {<<: *str_rpm}
alert:
string: {text: "{temp}°C {rpm} RPM", foreground: *col_fg_alert}
- string: {<<: *str_temp, foreground: *col_fg_alert}
- string: {<<: *str_rpm}
@ -177,32 +215,6 @@ bar:
right:
- cpu:
interval: 1500
content:
list:
spacing: 0
font: "Fira Code:size=12"
items:
- ramp:
tag: cpu0
items: &cpu_ramp
- empty: {} # 0-12
- empty: {} # 12-25
- empty: {} # 25-37
- empty: {} # 37-50
- empty: {} # 50-62
- string: {margin: 1, text: "▅", foreground: "666666ff" } # 62-75
- string: {margin: 1, text: "▆", foreground: "888888ff" } # 75-87
- string: {margin: 1, text: "▇", foreground: *col_fg_caution } # 87-100
- ramp: {tag: cpu1, items: *cpu_ramp}
- ramp: {tag: cpu2, items: *cpu_ramp}
- ramp: {tag: cpu3, items: *cpu_ramp}
- ramp: {tag: cpu4, items: *cpu_ramp}
- ramp: {tag: cpu5, items: *cpu_ramp}
- ramp: {tag: cpu6, items: *cpu_ramp}
- ramp: {tag: cpu7, items: *cpu_ramp}
- alsa:
card: hw:PCH
mixer: Master