On my laptop, I currently have:
services.logind.lidSwitch = "suspend-then-hibernate";
systemd.sleep.extraConfig = ''
HibernateDelaySec=2h
'';
And works every time when I close my lid, however, if I let my laptop sleep by inactivity, these settings do not take effect. If my leave my laptop asleep for a few days, I will find it dead/almost dead instead of hibernated. I cannot seem to find anything in documentation to make Gnome match the above settings.
Anyone have any ideas how I can achieve this?