diff options
Diffstat (limited to 'app-misc/sabayonlive-tools/files/2.3/cdeject')
-rw-r--r-- | app-misc/sabayonlive-tools/files/2.3/cdeject | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/app-misc/sabayonlive-tools/files/2.3/cdeject b/app-misc/sabayonlive-tools/files/2.3/cdeject deleted file mode 100644 index 6d56f04..0000000 --- a/app-misc/sabayonlive-tools/files/2.3/cdeject +++ /dev/null @@ -1,23 +0,0 @@ -#!/sbin/runscript -# Copyright (c) 2010 Fabio Erculiani <lxnay@sabayon.org> -# All rights reserved. Released under the 2-clause BSD license. - -description="Eject LiveCD/DVD at live system shutdown/reboot" - -depend() -{ - after * -} - -start() -{ - is_live=$(cat /proc/cmdline | grep cdroot) - if [ -n "${is_live}" ]; then - cdrom_dev=$(cat /proc/mounts | grep " /mnt/cdrom " | cut -d" " -f 1) - # check if /mnt/cdrom device is a cdrom device - if [ "${cdrom_dev}" = /dev/sr* ] || [ "${cdrom_dev}" = /dev/cdrom* ]; then - eject -mp "${cdrom_dev}" &> /dev/null - fi - fi - eend 0 -} |