On 30.03.2021 21:21, mh@mike.franken.de wrote:
Hi *,
on my notebook I use a small script to handle the connected graphics ports via xrandr. This script has to be run before sddm-greeter gets started. For a long time now the script was started from [/usr]/etc/X11/xdm/Xsetup,
/usr/etc is unlikely to be "for a long time". Also telling your distribution and version would be helpful.
because I couldn't find a better place for it. It is annoying, though, that Xsetup gets overwritten with every update of xdm. What's more annoying, is the fact, that no .rpmsave file is created during update, despite the fact I had modified the file.
If file is not changed between two package versions it should be left as is. rpmsave/rpmnew are created if file changed in package *and* was modified on disk. As /etc/X11/xdm/Xsetup was not changed in 5 years, this would explain why no rpmsave is created (but then it also should not be replaced). And files in /usr/etc are not intended to be editable, so these files are unconditionally overwritten on update - this is absolutely correct and expected behavior.
Is there a better/proper place for a script like that, where it can survive an update unchanged? Something like Xsetup.d/?
You can define any script you like in your display manager configuration. For SDDM this is probably DisplayCommand, but I am not familiar enough with it.