dotfiles/dot_config/yambar/config.yml.tmpl

412 lines
13 KiB
Cheetah
Raw Normal View History

# Colors
.catppuccin_mocha:
0: &foreground cdd6f4ff
1: &background 1e1e2edd
2: &black 45475aff
3: &dark_grey 45475aff
4: &dark_red f38ba8ff
5: &red f38ba8ff
6: &dark_green a6e3a1ff
7: &green a6e3a1ff
8: &dark_yellow f9e2afff
9: &yellow f9e2afff
10: &dark_blue 89b4faff
11: &blue 89b4faff
12: &dark_magenta f5c2e7ff
13: &magenta f5c2e7ff
14: &dark_cyan 94e2d5ff
15: &cyan 94e2d5ff
16: &light_grey bac2deff
17: &white a6adc8ff
transparent_light_grey: &transparent_light_grey bac2deaa
transparent_black: &transparent_black 45475aaa
# .everforest:
# 0: &foreground d8caacff
# 1: &background 323d43dd
# 2: &black 4a555bff
# 3: &dark_grey 525c62ff
# 4: &dark_red e26c6eff
# 5: &red e68183ff
# 6: &dark_green 9bb86fff
# 7: &green a7c080ff
# 8: &dark_yellow d5b26bff
# 9: &yellow dbbc7fff
# 10: &dark_blue 6eb2a9ff
# 11: &blue 7fbbb3ff
# 12: &dark_magenta cf87a9ff
# 13: &magenta d699b6ff
# 14: &dark_cyan 72b783ff
# 15: &cyan 83c092ff
# 16: &light_grey d0bf9bff
# 17: &white d8caacff
# transparent_light_grey: &transparent_light_grey d0bf9baa
# transparent_black: &transparent_black 4a555baa
# Fonts
2023-07-14 04:56:11 -04:00
{{- if eq .chezmoi.hostname "helix" }}
2023-07-19 21:59:45 -04:00
hack: &hack Hack:pixelsize=28
awesome: &awesome Font Awesome 6 Free:style=solid:pixelsize=28
2023-07-14 04:56:11 -04:00
{{- else}}
hack: &hack Hack:pixelsize=13
awesome: &awesome Font Awesome 6 Free:style=solid:pixelsize=12
{{- end }}
# Labels
separator:
&separator { string: { text: " ", font: *hack, foreground: *light_grey } }
2023-06-15 18:44:19 -04:00
bar:
2023-07-14 04:56:11 -04:00
{{- if eq .chezmoi.hostname "helix" }}
height: 64
2023-07-14 04:56:11 -04:00
location: top
{{- else if eq .chezmoi.hostname "hydrus" }}
monitor: DP-1
height: 28
2023-06-15 18:44:19 -04:00
location: bottom
2023-07-14 04:56:11 -04:00
{{- else }}
height: 36
location: top
{{- end }}
2023-06-15 18:44:19 -04:00
layer: top
spacing: 2
margin: 2
2023-07-14 01:07:01 -04:00
font: *hack
2023-06-15 18:44:19 -04:00
foreground: *foreground
background: *background
border:
2023-07-14 04:56:11 -04:00
{{- if eq .chezmoi.hostname "hydrus" }}
bottom-margin: 4
left-margin: 8
right-margin: 8
2023-07-14 04:56:11 -04:00
{{- else }}
top-margin: 8
left-margin: 16
right-margin: 16
2023-07-14 04:56:11 -04:00
{{- end }}
width: 0
color: *transparent_light_grey
2023-06-15 18:44:19 -04:00
left:
- river:
anchors:
- base: &river_base
2023-07-14 04:56:11 -04:00
{{- if eq .chezmoi.hostname "helix" }}
2023-07-14 01:07:01 -04:00
left-margin: 56
right-margin: 56
2023-07-14 04:56:11 -04:00
{{- else }}
left-margin: 22
right-margin: 22
{{- end }}
2023-06-15 18:44:19 -04:00
text: "{id}"
content:
map:
2023-07-14 01:07:01 -04:00
on-click:
left: sh -c "riverctl set-focused-tags $((1 << ({id} - 1)))"
middle: sh -c "riverctl toggle-view-tags $((1 << ({id} -1)))"
right: sh -c "riverctl toggle-focused-tags $((1 << ({id} -1)))"
{{- if eq .chezmoi.hostname "helix" }}
2023-06-15 18:44:19 -04:00
conditions:
urgent:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *dark_red } },
{ border: { size: 2, color: *black } },
],
}
2023-07-14 01:07:01 -04:00
foreground: *black
2023-06-15 18:44:19 -04:00
focused:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *light_grey } },
{ underline: { size: 1, color: *transparent_black } },
],
}
2023-07-14 01:07:01 -04:00
foreground: *dark_grey
2023-06-15 18:44:19 -04:00
visible && occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *transparent_light_grey } },
{ underline: { size: 1, color: *transparent_black } },
],
}
2023-07-14 04:56:11 -04:00
foreground: *light_grey
2023-06-15 18:44:19 -04:00
visible && ~occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *transparent_light_grey } },
{ underline: { size: 1, color: *transparent_black } },
],
}
2023-07-14 01:07:01 -04:00
foreground: *light_grey
2023-06-15 18:44:19 -04:00
~visible && occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *dark_grey } },
{
underline:
{ size: 1, color: *transparent_light_grey },
},
],
}
2023-07-14 01:07:01 -04:00
foreground: *light_grey
2023-07-14 04:56:11 -04:00
~focused && occupied:
2023-07-14 01:07:01 -04:00
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *dark_grey } },
{
underline:
{ size: 1, color: *transparent_light_grey },
},
],
}
2023-07-14 01:07:01 -04:00
foreground: *light_grey
2023-07-14 04:56:11 -04:00
id < 10 && ~visible && ~occupied:
2023-06-15 18:44:19 -04:00
string:
<<: *river_base
2023-07-14 01:07:01 -04:00
foreground: *light_grey
2023-07-14 04:56:11 -04:00
id >= 10 && ~visible && ~occupied: {empty: {}}
{{- else }}
conditions:
urgent:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *dark_red } },
{ border: { size: 2, color: *black } },
],
}
foreground: *black
focused:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *light_grey } },
{ underline: { size: 1, color: *transparent_black } },
],
}
foreground: *dark_grey
visible && occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *transparent_light_grey } },
{ underline: { size: 1, color: *transparent_black } },
],
}
foreground: *light_grey
visible && ~occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *transparent_light_grey } },
{ underline: { size: 1, color: *transparent_black } },
],
}
foreground: *light_grey
~visible && occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *dark_grey } },
{
underline:
{ size: 1, color: *transparent_light_grey },
},
],
}
foreground: *light_grey
~focused && occupied:
string:
<<: *river_base
deco:
{
stack:
[
{ background: { color: *dark_grey } },
{
underline:
{ size: 1, color: *transparent_light_grey },
},
],
}
foreground: *light_grey
id < 10 && ~visible && ~occupied:
string:
<<: *river_base
deco:
{ underline: { size: 1, color: *transparent_light_grey } }
foreground: *light_grey
id >= 10 && ~visible && ~occupied: { empty: {} }
{{ end }}
2023-07-14 01:07:01 -04:00
center:
- foreign-toplevel:
content:
map:
conditions:
activated:
- string: { text: "{app-id}: {title}" }
~activated: { empty: {} }
2023-06-15 18:44:19 -04:00
right:
2023-07-14 01:07:01 -04:00
- pulse:
content:
map:
2023-07-14 04:56:11 -04:00
on-click:
left: sh -c "pactl set-sink-mute @DEFAULT_SINK@ toggle"
wheel-up: sh -c "pactl set-sink-volume @DEFAULT_SINK@ +5%"
wheel-down: sh -c "pactl set-sink-volume @DEFAULT_SINK@ -5%"
2023-07-14 01:07:01 -04:00
conditions:
sink_muted:
- string:
{
text: ,
font: *awesome,
foreground: *transparent_light_grey,
}
- string:
{
text: " {sink_percent}% ({sink_port})",
foreground: *transparent_light_grey,
}
2023-07-14 01:07:01 -04:00
~sink_muted:
- ramp:
tag: sink_percent
items:
- string: { text: , font: *awesome }
- string: { text: , font: *awesome }
- string: { text: , font: *awesome }
- string: { text: " {sink_percent}% ({sink_port})" }
2023-07-14 04:56:11 -04:00
{{- if ne .chezmoi.hostname "hydrus" }}
2023-07-14 01:07:01 -04:00
- label:
content: *separator
- backlight:
name: amdgpu_bl1
2023-07-14 01:07:01 -04:00
content:
- ramp:
tag: percent
items:
- string: {text: , font: *awesome}
- string: {text: , font: *awesome}
- string: {text: " {percent}%"}
- label:
content: *separator
- network:
content:
map:
2024-04-28 07:48:43 -04:00
default: {empty: {}}
2023-07-14 01:07:01 -04:00
conditions:
2024-04-28 07:48:43 -04:00
name >= wlan0 && name <= wlan9:
2023-07-14 01:07:01 -04:00
map:
conditions:
2024-04-28 07:48:43 -04:00
~carrier: {empty: {}}
carrier:
map:
default:
- string: {text: , font: *awesome}
- string: {text: " {name}: {quality}%"}
conditions:
ipv4 == "":
- string: {text: , font: *awesome}
- string: {text: " {name}: {state}"}
- network:
content:
map:
2024-04-28 07:48:43 -04:00
default: {empty: {}}
conditions:
2024-04-28 07:48:43 -04:00
name >= eth0 && name <= eth9:
map:
conditions:
2024-04-28 07:48:43 -04:00
~carrier: {empty: {}}
carrier:
map:
default:
- string: {text: , font: *awesome}
- string: {text: " {name}: {state}"}
conditions:
state == down: {string: {text: , font: *awesome}}
ipv4 == "":
- string: {text: , font: *awesome}
- string: {text: " {name}: {state}"}
2023-07-14 01:07:01 -04:00
- label:
content: *separator
- battery:
name: BAT0
poll-interval: 5000
2023-07-14 01:07:01 -04:00
anchors:
discharging: &discharging
list:
items:
- ramp:
tag: capacity
items:
- string: {text: , foreground: *dark_red, font: *awesome}
- string: {text: , foreground: *dark_yellow, font: *awesome}
- string: {text: , font: *awesome}
- string: {text: , font: *awesome}
- string: {text: , font: *awesome}
- string: {text: " {capacity}% {estimate}"}
content:
map:
conditions:
state == unknown:
<<: *discharging
state == discharging:
<<: *discharging
state == charging:
- string: {text: , font: *awesome}
- string: {text: " {capacity}% {estimate}"}
state == full:
- string: {text: , foreground: *dark_green, font: *awesome}
- string: {text: " {capacity}% full", foreground: *dark_green}
state == "not charging":
- string: {text:  , font: *awesome}
- string: {text: " {capacity}%"}
2023-07-14 04:56:11 -04:00
{{- end }}
2023-07-14 01:07:01 -04:00
- label:
content: *separator
- clock:
2023-11-05 19:37:23 -05:00
date-format: "%a %b %d"
2023-07-14 01:07:01 -04:00
time-format: "%R"
content:
- string: { text: , font: *awesome }
- string: { text: " {date} " }
- string: { text: , font: *awesome }
- string: { text: " {time} " }