This commit is contained in:
Schrottkatze 2022-08-13 20:33:53 +02:00
parent 9833180135
commit 5bf4a00b13

View file

@ -90,6 +90,7 @@ in with lib; {
enable = true; enable = true;
package = pkgs.i3-gaps; package = pkgs.i3-gaps;
config = { config = {
bars = [];
terminal = "kitty"; terminal = "kitty";
workspaceAutoBackAndForth = true; workspaceAutoBackAndForth = true;
# Startup {{{ # Startup {{{
@ -257,6 +258,128 @@ in with lib; {
}; };
}; };
# }}} # }}}
# Polybar {{{
services.polybar = {
enable = true;
script = "pkill polybar; polybar & disown";
settings = {
colors = {
background = "#282828";
background-alt = "#3c3836";
foreground = "#ebdbb2";
primary = "#d65d0e";
secondary = "#fe8019";
alert = "#cc241d";
disabled = "#504945";
};
"bar/status" = {
# Style
width = "100%";
height = "24px";
radius = 0;
tray-position = "enter";
background = "\${colors.background}";
foreground = "\${colors.foreground}";
line-size = "4px";
border-color = "#00000000";
padding-left = 0;
padding-right = 1;
module-margin = 1;
separator = "|";
separator-foreground = "\${colors.disabled}";
font-0 = "FiraMono Nerd Font";
modules-left = "xworkspaces xwindow";
modules-right = "memory cpu wlan battery date";
cursor-click = "pointer";
cursor-scroll = "ns-resize";
enable-ipc = true;
wm-restack = "i3";
override-redirect = false;
};
"module/xworkspaces" = {
type = "internal/xworkspaces";
label-active = "";
label-active-padding = 1;
label-occupied = "";
label-occupied-padding = 1;
label-urgent = "";
label-urgent-foreground = "\${colors.alert}";
label-urgent-padding = 1;
label-empty = "";
label-empty-foreground = "\${colors.disabled}";
label-empty-padding = 1;
};
"module/xwindow" = {
type = "internal/xwindow";
label = "%title:0:60:...%";
};
"module/memory" = {
type = "internal/memory";
interval = 2;
format-prefix = " ";
format-prefix-foreground = "\${colors.primary}";
label = "%percentage_used:2%%";
};
"module/cpu" = {
type = "internal/cpu";
interval = "2";
format-prefix = " ";
format-prefix-foreground = "\${colors.primary}";
label = "%percentage:2%%";
};
"network-base" = {
type = "internal/network";
interval = 5;
format-connected = "<label-connected>";
format-disconnected = "<label-disconnected>";
label-disconnected = "%{F#F0C674}%ifname%%{F#707880} disconnected";
};
"module/wlan" = {
"inherit" = "network-base";
interface-type = "wireless";
label-connected = "%{F#F0C674}%ifname%%{F-} %essid% %local_ip%";
};
"module/battery" = {
type = "internal/battery";
poll-interval = 5;
full-at = 96;
battery = "BAT0";
adapter = "ADP1";
time-format = "%H:%M";
label-charging = "%percentage%% %time%";
format-charging = "<ramp-capacity> <label-charging>";
label-discharging = "%percentage%% %time%";
format-discharging = "<ramp-capacity> <label-discharging>";
label-full = "%percentage%%";
format-full = " <label-full>";
label-low = "%percentage%%";
format-low = " <label-low>";
ramp.capacity = [ "" "" "" "" "" "" "" "" "" "" ];
};
"module/date" = {
type = "internal/date";
interval = 1;
date = "%Y-%m-%d %H:%M:%S";
label = "%date%";
label-foreground = "\${colors.foreground}";
};
"settings" = {
screenchange-reload = true;
pseudo-transparency = true;
};
};
};
# }}}
}; };
}; };
} }