+pis hoffentlich final

This commit is contained in:
sascha.koenig 2025-11-26 13:12:40 +01:00
parent e2e81dee82
commit 1c05d7800d
5 changed files with 37 additions and 37 deletions

View File

@ -19,8 +19,6 @@
exec-once = [
"start-browsers"
];
monitor = [
];
workspace = [
"1, monitor:HDMI-A-1, default:true"
"2, monitor:HDMI-A-2"

View File

@ -20,10 +20,7 @@
"start-browsers"
];
monitor = [
];
workspace = [
"1, monitor:eDP-1, default:true"
"2, monitor:eDP-1"
"HDMI-A-1,1920x1080,0x0,1"
];
};
}

View File

@ -16,13 +16,9 @@
"WLR_NO_HARDWARE_CURSORS,1"
];
exec-once = [
"chromium $WEBAPP_URL"
"chromium --app=$WEBAPP_URL"
];
monitor = [
];
workspace = [
"1, monitor:eDP-1, default:true"
"2, monitor:eDP-1"
];
};
}

View File

@ -16,13 +16,7 @@
"WLR_NO_HARDWARE_CURSORS,1"
];
exec-once = [
"chromium $WEBAPP_URL"
];
monitor = [
];
workspace = [
"1, monitor:eDP-1, default:true"
"2, monitor:eDP-1"
"chromium --app=$WEBAPP_URL"
];
};
}

View File

@ -27,12 +27,12 @@
home.packages = with pkgs; [
rose-pine-hyprcursor
nitch
rustdesk
# Create an isolated chromium instance with separate user data directory
(pkgs.writeShellScriptBin "chromium-isolated" ''
exec ${pkgs.chromium}/bin/chromium \
--user-data-dir="$HOME/.config/chromium-isolated" \
--password-store=basic \
--kiosk \
--ozone-platform=x11 \
--disable-restore-session-state \
--disable-session-crashed-bubble \
@ -46,21 +46,33 @@
(pkgs.writeShellScriptBin "start-browsers" ''
#!/bin/bash
# Workspace 1 aktivieren und Chromium starten
${pkgs.hyprland}/bin/hyprctl dispatch workspace 1
chromium "$WEBAPP_URL" &
# Anzahl der Monitore abfragen
MONITOR_COUNT=$(${pkgs.hyprland}/bin/hyprctl -j monitors | ${pkgs.jq}/bin/jq 'length')
# Warten, bis Chromium-Fenster zu sehen ist
while true; do
if ${pkgs.hyprland}/bin/hyprctl -j clients | ${pkgs.jq}/bin/jq -e '.[] | select(.class == "Chromium-browser")' >/dev/null; then
break
fi
sleep 0.2
done
if [ "$MONITOR_COUNT" -gt 1 ]; then
# Multi-Monitor-Setup: Workspace-Wechsel durchführen
# Danach Workspace 2 und zweiten Browser starten
${pkgs.hyprland}/bin/hyprctl dispatch workspace 2
chromium-isolated "$WEBAPP_URL1" &
# Workspace 1 aktivieren und Chromium starten
${pkgs.hyprland}/bin/hyprctl dispatch workspace 1
chromium --app="$WEBAPP_URL" &
# Warten, bis Chromium-Fenster zu sehen ist
while true; do
if ${pkgs.hyprland}/bin/hyprctl -j clients | ${pkgs.jq}/bin/jq -e '.[] | select(.class | ascii_downcase | contains("chromium"))' >/dev/null; then
break
fi
sleep 0.2
done
# Danach Workspace 2 und zweiten Browser starten
${pkgs.hyprland}/bin/hyprctl dispatch workspace 2
chromium-isolated --app="$WEBAPP_URL1" &
else
# Single-Monitor-Setup: Beide Browser ohne Workspace-Wechsel starten
chromium --app="$WEBAPP_URL" &
sleep 2 # Kurze Pause zwischen den Starts
chromium-isolated --app="$WEBAPP_URL1" &
fi
'')
# # Adds the 'hello' command to your environment. It prints a friendly
# # "Hello, world!" when run.
@ -100,7 +112,6 @@
enable = true;
commandLineArgs = [
"--password-store=basic"
"--kiosk"
"--ozone-platform=x11"
"--disable-restore-session-state"
"--disable-session-crashed-bubble"
@ -133,9 +144,9 @@
inactive_timeout = 1.0;
};
general = {
gaps_in = 5;
gaps_out = 5;
border_size = 1;
gaps_in = 0;
gaps_out = 0;
border_size = 0;
"col.active_border" = "rgba(9742b5ee) rgba(9742b5ee) 45deg";
"col.inactive_border" = "rgba(44475aaa)";
"col.nogroup_border" = "rgba(282a36dd)";
@ -148,7 +159,7 @@
shadow = {
enabled = false;
};
rounding = 8;
rounding = 0;
blur = {
enabled = false;
};
@ -186,6 +197,10 @@
"float, title:branchdialog"
"bordercolor rgb(ffffff),xwayland:1"
"workspace 1,class:(chromium-browser)"
"tile,class:^(chromium)$"
"tile,class:^(Chromium)$"
"tile,class:^(chromium-browser)$"
"tile,class:^(Chromium-browser)$"
];
"$mainMod" = "SUPER";