/etc/acpi/sleep_suspend.sh is in acpi-support 0.142-8.
This file is owned by root:root, with mode 0o755.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #!/bin/sh
# This script HANDLES the sleep or suspend button (does not TRANSLATE it). It
# is part of the *suspend* side of acpi-support, not the special keys
# translation side. If this script is called, it is assumed to be the result of
# a suspend key press that can also be heard by other parts of the system. The
# only time that it actually does something is when it is determined that no
# other parts of the system are listening (this is what the CheckPolicy call
# does).
test -f /usr/share/acpi-support/key-constants || exit 0
. /etc/default/acpi-support
. /usr/share/acpi-support/policy-funcs
if { CheckPolicy || HasLogindAndSystemd1Manager; }; then
exit
fi
[ x$1 != xsleep ] || [ x$ACPI_SLEEP = xtrue ] || exit 0
[ x$1 != xsuspend ] || [ x$ACPI_HIBERNATE = xtrue ] || exit 0
if [ x$LOCK_SCREEN = xtrue ]; then
. /usr/share/acpi-support/screenblank
fi
if [ x$1 = xsleep ]; then
pm-suspend
elif [ x$1 = xsuspend ]; then
pm-hibernate
fi
|