livecd-tools/tools/eject_cd.sh

12 lines
354 B
Bash
Raw Normal View History

2011-04-26 13:21:24 +02:00
#! /bin/sh
#
# eject_cd.sh - openmamba livecd eject CD and halt/reboot script
2011-04-26 13:21:24 +02:00
#
# Copyright (c) 2003-2013 by Silvan Calarco <silvan.calarco@qilinux.it>
2011-04-26 13:21:24 +02:00
# Copyright (c) 2003-2004 by Davide Madrisan <davide.madrisan@qilinux.it>
# FIXME: support SCSI cdroms
CDROMDEV=`cat /etc/mtab | sed -n '/ \/cdrom /{h;s/ .*//p}'`
# eject live CDROM
eject -m $CDROMDEV