waybar works but setup not completely done

This commit is contained in:
KoenDR06 2025-08-25 23:27:29 +02:00
parent 79942ed4ad
commit 90966f1b3e
4 changed files with 357 additions and 1 deletions

View file

@ -6,6 +6,7 @@
}: let
inherit (lib) mkIf mkEnableOption;
cfg = config.horseman.wm.hyprland;
homeCfg = config.horseman;
in {
imports = [
./options.nix
@ -44,6 +45,194 @@ in {
xdg-desktop-portal-hyprland
];
home-manager.users.${homeCfg.username} = {
programs.waybar = {
enable = true;
settings = {
horizontalBar = {
layer = "top";
position = "top";
output = [
"DP-3"
];
modules-left = ["group/power"];
modules-center = ["hyprland/workspaces"];
modules-right = ["network" "pulseaudio" "memory" "cpu" "clock"];
"clock" = {
interval = 1;
format = "{:%H:%M:%S}";
tooltip-format = "{:%a %d %b %Y}";
};
"cpu" = {
interval = 3;
format = " {usage}%";
on-click = "kitty btop &";
};
"memory" = {
interval = 3;
format = " {percentage}%";
on-click = "kitty btop &";
};
"pulseaudio" = {
format = " {volume}";
on-click = "kitty pulsemixer &";
};
"network" = {
interval = 3;
format = "{ipaddr}";
format-ethernet = " {ipaddr}";
format-disconnected = "󰣽 Disconnected";
format-wifi = "󰤨 {essid}";
tooltip = false;
};
"battery" = {
interval = 3;
# TODO This needs to be fixed
};
"hyprland/workspaces" = {
format = "{icon}";
format-icons = {
"active" = "";
"default" = "";
"empty" = "";
};
persistent-workspaces = {
"*" = [1 2 3 4 5 6 7 8 9 10];
};
};
"group/power" = {
orientation = "horizontal";
drawer = {
};
modules = [
"custom/power"
"custom/reboot"
"custom/lock"
"idle_inhibitor"
];
};
"custom/lock" = {
format = "󰍁 ";
tooltip = false;
on-click = "hyprlock";
};
"custom/reboot" = {
format = "󰜉 ";
tooltip = false;
on-click = "reboot";
};
"custom/power" = {
format = " ";
tooltip = false;
on-click = "shutdown now";
};
"idle_inhibitor" = {
tooltip = false;
format = "{icon}";
format-icons = {
deactivated = "󰒲 ";
activated = "󰒳 ";
};
};
};
verticalBar = {
layer = "top";
position = "right";
output = [
"eDP-1"
];
modules-left = ["group/power"];
modules-center = ["hyprland/workspaces"];
modules-right = ["battery" "clock"];
"clock" = {
interval = 1;
format = "{:%H\n%M\n%S}";
tooltip-format = "{:%a %d %b %Y}";
};
"cpu" = {
interval = 3;
format = "\n{usage}%";
on-click = "kitty btop &";
};
"memory" = {
interval = 3;
format = "\n{percentage}%";
on-click = "kitty btop &";
};
"battery" = {
interval = 3;
# TODO This needs to be fixed
};
"hyprland/workspaces" = {
format = "{icon}";
format-icons = {
"active" = "";
"default" = "";
"empty" = "";
};
persistent-workspaces = {
"*" = [1 2 3 4 5 6 7 8 9 10];
};
};
"group/power" = {
orientation = "vertical";
drawer = {
};
modules = [
"custom/power"
"custom/reboot"
"custom/lock"
"idle_inhibitor"
];
};
"custom/lock" = {
format = "󰍁 ";
tooltip = false;
on-click = "hyprlock";
};
"custom/reboot" = {
format = "󰜉 ";
tooltip = false;
on-click = "reboot";
};
"custom/power" = {
format = " ";
tooltip = false;
on-click = "shutdown now";
};
"idle_inhibitor" = {
tooltip = false;
format = "{icon}";
format-icons = {
deactivated = "󰒲 ";
activated = "󰒳 ";
};
};
};
};
};
xdg.configFile."waybar/style.css".source = ./config/waybar/style.css;
};
horseman.wm.hyprland.config = {
execOnce = [
"hyprpaper"
@ -52,6 +241,7 @@ in {
"hyprpaper"
"swaync"
"systemctl --user start hyprpolkitagent"
"waybar"
];
env = [
@ -313,7 +503,7 @@ in {
binds = {
workspaceCenterOn = 1;
dragThreshold = 50;
dragThreshold = 0;
};
ecosystem = {