From 0e7f2ada72de95814a6c7bc0e1e3d0b884368b09 Mon Sep 17 00:00:00 2001 From: jasmine Date: Sun, 21 Dec 2025 12:51:17 +0800 Subject: [PATCH] fix(jade): resolve Thunar 20s startup delay Import DISPLAY and XAUTHORITY into systemd user environment and restart xdg-desktop-portal-gtk service in xinitrc. This fixes the issue where portal backends fail to start with "cannot open display" error when using startx instead of a display manager. Without this, Thunar waits 25 seconds for org.freedesktop.portal.Desktop to respond before timing out and displaying. --- nixos/common/users/sajenim/jade/xinitrc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/nixos/common/users/sajenim/jade/xinitrc b/nixos/common/users/sajenim/jade/xinitrc index b7475f8..3560c78 100644 --- a/nixos/common/users/sajenim/jade/xinitrc +++ b/nixos/common/users/sajenim/jade/xinitrc @@ -13,5 +13,11 @@ xset s off -dpms # Fix for pinentry bug on NixOS gpgconf --reload gpg-agent +# Import X display into systemd user environment +systemctl --user import-environment DISPLAY XAUTHORITY + +# Start XDG desktop portal backend +systemctl --user restart xdg-desktop-portal-gtk.service + # Launch window manager exec xmonad