trying to get hyprland to latest latest version to fix crashing windows... it did not work

This commit is contained in:
RingOfStorms (Joshua Bell) 2025-08-30 18:28:00 -05:00
parent 7f706e870e
commit 85b427cb12
12 changed files with 1090 additions and 69 deletions

View file

@ -8,17 +8,22 @@ let
secondaryMonitor = "desc:${secondaryDesc}";
hyprlandExtraOptions = {
exec-once = [
# Wait a moment for monitors/workspaces to settle, then "prime" 6 and return to 1
"sh -lc 'sleep 0.2; hyprctl dispatch workspace 7; sleep 0.02; hyprctl dispatch workspace 1'"
];
monitor = [
"${mainMonitor},3840x2160@97.98,0x0,1,transform,0"
"${secondaryMonitor},3440x1440@99.98,-1440x-640,1,transform,1"
];
# workspace =
# let
# inherit (builtins) map toString;
# inherit (lib) range;
# mkWs = monitor: i: "${toString i},persistent:true";
# in
# (map (mkWs mainMonitor) (range 1 6)) ++ (map (mkWs secondaryMonitor) (range 7 10));
workspace =
let
inherit (builtins) map toString;
inherit (lib) range;
mkWs = monitor: i: "${toString i},monitor:${monitor},persistent:true";
in
(map (mkWs mainMonitor) (range 1 6)) ++ (map (mkWs secondaryMonitor) (range 7 10));
};
moveScript = pkgs.writeShellScriptBin "hyprland-move-workspaces" ''
@ -120,9 +125,14 @@ in
# User-level systemd service that follows your Hyprland session and watches for monitor changes
systemd.user.services.hyprland-move-workspaces = {
description = "Keep workspaces 16 on main and 710 on secondary; react to monitor changes";
wants = [ "graphical-session.target" ];
after = [ "graphical-session.target" ];
partOf = [ "graphical-session.target" ];
# Start/stop with Hyprland specifically
wantedBy = [ "hyprland-session.target" ];
after = [ "hyprland-session.target" ];
partOf = [ "hyprland-session.target" ];
bindsTo = [ "hyprland-session.target" ];
# Only start once Hyprland's event socket exists
unitConfig.ConditionPathExistsGlob = "%t/hypr/*/.socket2.sock";
serviceConfig = {
Type = "simple";