build/packages/bsp/pinebook/pinebook-restore-sound-after-resume.service

15 lines
368 B
Desktop File

[Unit]
Description=Restore sound after resume
After=suspend.target
After=tmp.mount
ConditionPathExists=/tmp/.before-suspend-asound.state
ConditionFileIsExecutable=/usr/sbin/alsactl
[Service]
Type=oneshot
ExecStart=/usr/sbin/alsactl -f /tmp/.before-suspend-asound.state restore
ExecStart=/bin/rm -f /tmp/.before-suspend-asound.state
[Install]
WantedBy=suspend.target