From 3389e89ec7b6f42ac4a1a6ddeb47fc5a1628c3bb Mon Sep 17 00:00:00 2001 From: Arpit Chakladar Date: Mon, 9 Mar 2026 20:26:17 +0530 Subject: Some minor code refactoring --- modules/desktop/polybar/module/battery.nix | 10 +++++----- modules/desktop/polybar/module/bspwm.nix | 8 ++++---- modules/desktop/polybar/module/ethernet-separator.nix | 4 ++-- modules/desktop/polybar/module/ethernet.nix | 4 ++-- modules/desktop/polybar/module/wifi-separator.nix | 4 ++-- modules/desktop/polybar/module/wifi.nix | 6 +++--- modules/desktop/polybar/module/xwindow.nix | 1 - 7 files changed, 18 insertions(+), 19 deletions(-) (limited to 'modules/desktop/polybar/module') diff --git a/modules/desktop/polybar/module/battery.nix b/modules/desktop/polybar/module/battery.nix index f2a10c8..cdf3b86 100644 --- a/modules/desktop/polybar/module/battery.nix +++ b/modules/desktop/polybar/module/battery.nix @@ -5,15 +5,15 @@ with config.scheme.withHashtag; type = "internal/battery"; battery = "BAT1"; adapter = "ADP1"; - + low-at = 0; format-charging = "%{T2}%{F${base03}}%{F-}%{T-} "; format-discharging = "%{T2}%{F${base03}}%{F-}%{T-} "; format-full-prefix = "󰁹 "; - + label-charging = "%percentage:3%%"; label-discharging = "%percentage:3%%"; - + ramp-capacity-0 = "󰁺"; ramp-capacity-1 = "󰁻"; ramp-capacity-2 = "󰁼"; @@ -24,7 +24,7 @@ with config.scheme.withHashtag; ramp-capacity-7 = "󰂁"; ramp-capacity-8 = "󰂂"; ramp-capacity-9 = "󰁹"; - + animation-charging-0 = "󰁺"; animation-charging-1 = "󰁻"; animation-charging-2 = "󰁼"; @@ -35,6 +35,6 @@ with config.scheme.withHashtag; animation-charging-7 = "󰂁"; animation-charging-8 = "󰂂"; animation-charging-9 = "󰁹"; - + animation-charging-framerate = 750; } diff --git a/modules/desktop/polybar/module/bspwm.nix b/modules/desktop/polybar/module/bspwm.nix index 383de8f..3c8f64a 100644 --- a/modules/desktop/polybar/module/bspwm.nix +++ b/modules/desktop/polybar/module/bspwm.nix @@ -3,18 +3,18 @@ with config.scheme.withHashtag; { type = "internal/bspwm"; - + label-focused = "%index%"; label-focused-underline = "${base0D}"; label-focused-padding = 1; - + label-occupied = "%index%"; label-occupied-padding = 1; - + label-urgent = "%index%"; label-urgent-underline = "${base08}"; label-urgent-padding = 1; - + label-empty = "%index%"; label-empty-foreground = "${base03}"; label-empty-padding = 1; diff --git a/modules/desktop/polybar/module/ethernet-separator.nix b/modules/desktop/polybar/module/ethernet-separator.nix index 87df6f3..c2fefaa 100644 --- a/modules/desktop/polybar/module/ethernet-separator.nix +++ b/modules/desktop/polybar/module/ethernet-separator.nix @@ -5,10 +5,10 @@ with config.scheme.withHashtag; type = "internal/network"; interface = "enp4s0"; interface-type = "wired"; - + format-connected = " %{F${base03}}%{T3}│%{T-}%{F-} "; format-disconnected = ""; - + label-connected = ""; label-disconnected = ""; } diff --git a/modules/desktop/polybar/module/ethernet.nix b/modules/desktop/polybar/module/ethernet.nix index 9073c79..3e2b48d 100644 --- a/modules/desktop/polybar/module/ethernet.nix +++ b/modules/desktop/polybar/module/ethernet.nix @@ -5,10 +5,10 @@ with config.scheme.withHashtag; type = "internal/network"; interface = "enp4s0"; interface-type = "wired"; - + format-connected = "%{T2}%{F${base03}}%{F-}%{T-} "; format-disconnected = ""; - + label-connected = "%netspeed:8%"; label-disconnected = ""; } diff --git a/modules/desktop/polybar/module/wifi-separator.nix b/modules/desktop/polybar/module/wifi-separator.nix index 4237d84..6b8da50 100644 --- a/modules/desktop/polybar/module/wifi-separator.nix +++ b/modules/desktop/polybar/module/wifi-separator.nix @@ -5,10 +5,10 @@ with config.scheme.withHashtag; type = "internal/network"; interface = "wlan0"; interface-type = "wireless"; - + format-connected = " %{F${base03}}%{T3}│%{T-}%{F-} "; format-disconnected = ""; - + label-connected = ""; label-disconnected = ""; } diff --git a/modules/desktop/polybar/module/wifi.nix b/modules/desktop/polybar/module/wifi.nix index f244054..9f25fa2 100644 --- a/modules/desktop/polybar/module/wifi.nix +++ b/modules/desktop/polybar/module/wifi.nix @@ -5,13 +5,13 @@ with config.scheme.withHashtag; type = "internal/network"; interface = "wlan0"; interface-type = "wireless"; - + format-connected = "%{T2}%{F${base03}}%{F-}%{T-} "; format-disconnected = ""; - + label-connected = "%netspeed:8%"; label-disconnected = ""; - + ramp-signal-0 = "󰢼"; ramp-signal-1 = "󰢼"; ramp-signal-2 = "󰢽"; diff --git a/modules/desktop/polybar/module/xwindow.nix b/modules/desktop/polybar/module/xwindow.nix index f0614d1..386efe2 100644 --- a/modules/desktop/polybar/module/xwindow.nix +++ b/modules/desktop/polybar/module/xwindow.nix @@ -1,6 +1,5 @@ { config }: -with config.scheme.withHashtag; { type = "internal/xwindow"; label = "%title:0:20:...%"; -- cgit v1.2.3