Is that a “well-known” script that’s documented somewhere, or something you came up with @Sven ? (or both? )
I’d love to learn more about it.
Edit: I found a mention of qubes-app-shutdown-idle
in this other post. I think that’s likely the script you mentioned @Sven, isn’t it?