3 ms·
I was inspired this morning to try, and switching to a virtual terminal before suspending seems to work in my case! [Unit] Description=Switches to a TTY be
by sgtnoodle 4y ago
I was inspired this morning to try, and switching to a virtual terminal before suspending seems to work in my case!
[Unit]
Description=Switches to a TTY before suspending
Before=sleep.target
StopWhenUnneeded=yes
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=/bin/bash -c 'fgconsole >
/tmp/fix_resume_active_console'
ExecStart=/usr/bin/chvt 1
ExecStop=/bin/bash -c '/usr/bin/chvt $(cat
/tmp/fix_resume_active_console)'
[Install]
WantedBy=sleep.target