mirror of
https://github.com/SqrtMinusOne/dotfiles.git
synced 2025-12-10 19:23:03 +03:00
polybar: add temp
This commit is contained in:
parent
fa4a3d49f8
commit
23e102db15
3 changed files with 44 additions and 17 deletions
|
|
@ -27,16 +27,9 @@ gright =
|
|||
; Glyph settings:1 ends here
|
||||
|
||||
; [[file:../../Desktop.org::*Generating glyphs][Generating glyphs:3]]
|
||||
[module/glyph-light-cyan--cyan]
|
||||
[module/glyph-light-cyan--light-cyan]
|
||||
type = custom/text
|
||||
content-background = ${colors.light-cyan}
|
||||
content-foreground = ${colors.cyan}
|
||||
content = ${glyph.gright}
|
||||
content-font = 5
|
||||
|
||||
[module/glyph-magenta--light-cyan]
|
||||
type = custom/text
|
||||
content-background = ${colors.magenta}
|
||||
content-foreground = ${colors.light-cyan}
|
||||
content = ${glyph.gright}
|
||||
content-font = 5
|
||||
|
|
@ -97,10 +90,17 @@ content-foreground = ${colors.light-green}
|
|||
content = ${glyph.gright}
|
||||
content-font = 5
|
||||
|
||||
[module/glyph-magenta--cyan]
|
||||
[module/glyph-light-cyan--cyan]
|
||||
type = custom/text
|
||||
content-background = ${colors.light-cyan}
|
||||
content-foreground = ${colors.cyan}
|
||||
content = ${glyph.gright}
|
||||
content-font = 5
|
||||
|
||||
[module/glyph-magenta--light-cyan]
|
||||
type = custom/text
|
||||
content-background = ${colors.magenta}
|
||||
content-foreground = ${colors.cyan}
|
||||
content-foreground = ${colors.light-cyan}
|
||||
content = ${glyph.gright}
|
||||
content-font = 5
|
||||
|
||||
|
|
@ -421,6 +421,19 @@ ramp-capacity-3 =
|
|||
ramp-capacity-4 =
|
||||
; battery:1 ends here
|
||||
|
||||
; [[file:../../Desktop.org::*temperature][temperature:1]]
|
||||
[module/temperature]
|
||||
type = internal/temperature
|
||||
interval = 10
|
||||
|
||||
format = <label>
|
||||
format-foreground = ${colors.foreground}
|
||||
format-background = ${colors.light-cyan}
|
||||
format-warn = <label-warn>
|
||||
format-warn-foreground = ${colors.foreground}
|
||||
format-warn-background = ${colors.light-cyan}
|
||||
; temperature:1 ends here
|
||||
|
||||
; [[file:../../Desktop.org::*weather][weather:2]]
|
||||
[module/weather]
|
||||
type = custom/script
|
||||
|
|
|
|||
14
Desktop.org
14
Desktop.org
|
|
@ -1926,6 +1926,7 @@ As we want to interweave polybar modules with these glyphs in the right order an
|
|||
|-------+-------------+---------------+-------|
|
||||
| 1 | pulseaudio | light-magenta | + |
|
||||
| 2 | mpd | magenta | + |
|
||||
| 15 | temperature | light-cyan | + |
|
||||
| 9 | battery | light-cyan | + |
|
||||
| 3 | cpu | cyan | + |
|
||||
| 4 | ram-memory | light-green | + |
|
||||
|
|
@ -2650,6 +2651,19 @@ ramp-capacity-3 =
|
|||
ramp-capacity-4 =
|
||||
#+end_src
|
||||
|
||||
*** temperature
|
||||
#+begin_src conf-windows :noweb yes
|
||||
[module/temperature]
|
||||
type = internal/temperature
|
||||
interval = 10
|
||||
|
||||
format = <label>
|
||||
format-foreground = ${colors.foreground}
|
||||
format-background = <<get-polybar-bg(module="battery")>>
|
||||
format-warn = <label-warn>
|
||||
format-warn-foreground = ${colors.foreground}
|
||||
format-warn-background = <<get-polybar-bg(module="battery")>>
|
||||
#+end_src
|
||||
*** weather
|
||||
Gets current weather from [[http://wttr.in/][wttr.in]]
|
||||
#+begin_src bash :tangle ./bin/polybar/weather.sh
|
||||
|
|
|
|||
|
|
@ -45,13 +45,13 @@ declare -A BAR_HEIGHT=(
|
|||
["DP-1"]="29"
|
||||
)
|
||||
declare -A BLOCKS=(
|
||||
["eDP"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan battery glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["eDP-1"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan battery glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["DVI-D-0"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["HDMI-A-0"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["HDMI-1"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan battery glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["HDMI-0"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["DP-1"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["eDP"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--light-cyan battery glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["eDP-1"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--light-cyan battery glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["DVI-D-0"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["HDMI-A-0"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["HDMI-1"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--light-cyan battery glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["HDMI-0"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
["DP-1"]="glyph-background--light-magenta pulseaudio glyph-light-magenta--magenta mpd glyph-magenta--light-cyan temperature glyph-light-cyan--cyan cpu glyph-cyan--light-green ram-memory glyph-light-green--green swap-memory glyph-green--light-red bandwidth openvpn glyph-light-red--red xkeyboard glyph-red--light-yellow weather glyph-light-yellow--yellow sun glyph-yellow--light-blue aw-afk glyph-light-blue--blue date glyph-blue--background "
|
||||
)
|
||||
|
||||
# Geolocation for some modules
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue