Compare commits

..

No commits in common. "4660bc004601c3592f1f3040810bfb8d25760973" and "8a4d6ba1cb7314d8a45a78ba672bd293fd44ecd6" have entirely different histories.

2 changed files with 8 additions and 21 deletions

View file

@ -1,8 +1,8 @@
{pkgs, ...}: { {pkgs, ...}: {
wayland.windowManager.hyprland.settings = { wayland.windowManager.hyprland.settings = {
exec-once = [ exec-once = [
"${pkgs.systemd}/bin/systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP GTK_THEME QT_QPA_PLATFORMTHEME QT_STYLE_OVERRIDE" "${pkgs.systemd}/bin/systemctl --user import-environment WAYLAND_DISPLAY XDG_CURRENT_DESKTOP"
"${pkgs.systemd}/bin/dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP GTK_THEME QT_QPA_PLATFORMTHEME QT_STYLE_OVERRIDE" "${pkgs.systemd}/bin/dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=$XDG_CURRENT_DESKTOP"
]; ];
}; };
} }

View file

@ -15,20 +15,10 @@
tuiGreetTheme = "'border=magenta;text=cyan;prompt=green;time=red;action=white;button=yellow;container=black;input=gray'"; tuiGreetTheme = "'border=magenta;text=cyan;prompt=green;time=red;action=white;button=yellow;container=black;input=gray'";
sessionData = config.services.displayManager.sessionData.desktops; sessionData = config.services.displayManager.sessionData.desktops;
sessionPaths = concatStringsSep ":" [
# Run the session / application using the appropriate shell configured for this user. "${sessionData}/share/xsessions"
# This will make sure all of the environment variables are set before the WM session "${sessionData}/share/wayland-sessions"
# is started. This is very important, as without it, variables for things like qt theme ];
# will not be set, and applications executed by the WM will not be themed properly.
sessionWrapperScript = pkgs.writeShellScriptBin "tuigreet-session-wrapper" ''
set -euo pipefail
script_name="$0"
shell="$(getent passwd itsdrike | awk -F: '{print $NF}')"
command=("$@")
exec "$shell" -c 'exec "$@"' "$script_name" "''${command[@]}"
'';
defaultSession = { defaultSession = {
user = "greeter"; user = "greeter";
@ -39,11 +29,8 @@
"--remember-user-session" "--remember-user-session"
"--asterisks" "--asterisks"
"--greeting ${greetingMsg}" "--greeting ${greetingMsg}"
"--sessions '${sessionPaths}'"
"--theme ${tuiGreetTheme}" "--theme ${tuiGreetTheme}"
"--sessions '${sessionData}/share/wayland-sessions'"
"--xsessions '${sessionData}/share/xsessions'"
"--session-wrapper ${sessionWrapperScript}/bin/tuigreet-session-wrapper"
"--xsession-wrapper ${sessionWrapperScript}/bin/tuigreet-session-wrapper startx /usr/bin/env \"$@\""
]; ];
}; };
in { in {
@ -65,7 +52,7 @@ in {
# See: https://github.com/apognu/tuigreet/issues/68#issuecomment-1586359960 # See: https://github.com/apognu/tuigreet/issues/68#issuecomment-1586359960
systemd.services.greetd.serviceConfig = { systemd.services.greetd.serviceConfig = {
Type = "idle"; Type = "idle";
StandardInput = "tty"; StandardInputs = "tty";
StandardOutput = "tty"; StandardOutput = "tty";
StandardError = "journal"; StandardError = "journal";
TTYReset = true; TTYReset = true;