Sisyphus repositório
Última atualização: 19 outubro 2019 | SRPMs: 17506 | Visitas: 15302251
en ru br
ALT Linux repositórios
S:1.39-alt8
5.0: 1.23-alt1
4.1: 1.17-alt1.1
4.0: 1.14-alt1

Group :: Sistema/Kernel e hardware
RPM: pommed

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs e FR  Repocop 

#!/bin/sh
#
# pommed - Apple laptops hotkeys event handler
#
# chkconfig: 2345 36 90
# description: pommed handles the hotkeys found on the Apple MacBook Pro \
# and MacBook laptops and adjusts the LCD backlight, sound \
# volume, keyboard backlight or ejects the CD-ROM drive \
# accordingly.
# processname: pommed
# config: /etc/pommed.conf
# pidfile: /var/run/pommed.pid
### BEGIN INIT INFO
# Provides: pommed
# Required-Start: $local_fs messagebus
# Required-Stop: $local_fs messagebus
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Apple laptops hotkeys event handler
# Description: pommed handles the hotkeys found on the Apple MacBook Pro \
# and MacBook laptops and adjusts the LCD backlight, sound \
# volume, keyboard backlight or ejects the CD-ROM drive \
# accordingly.
### END INIT INFO

# Do not load RH compatibility interface.
WITHOUT_RC_COMPAT=1

# Source function library.
. /etc/init.d/functions

PIDFILE=/var/run/pommed.pid
LOCKFILE=/var/lock/subsys/pommed
RETVAL=0

start()
{
action "Loading applesmc kernel module:" modprobe applesmc
start_daemon --pidfile "$PIDFILE" --lockfile "$LOCKFILE" --expect-user root -- pommed
RETVAL=$?
return $RETVAL
}

stop()
{
stop_daemon --pidfile "$PIDFILE" --lockfile "$LOCKFILE" --expect-user root -- pommed
RETVAL=$?
return $RETVAL
}

restart()
{
stop
start
}

reload()
{
restart
}

# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
reload)
reload
;;
restart)
restart
;;
condstop)
if [ -e "$LOCKFILE" ]; then
stop
fi
;;
condrestart)
if [ -e "$LOCKFILE" ]; then
restart
fi
;;
condreload)
if [ -e "$LOCKFILE" ]; then
reload
fi
;;
status)
status --pidfile "$PIDFILE" --expect-user root -- pommed
RETVAL=$?
;;
*)
msg_usage "${0##*/} {start|stop|reload|restart|condstop|condrestart|condreload|status}"
RETVAL=1
esac

exit $RETVAL
 
projeto & código: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
mantenedor atual: Michael Shigorin
mantenedor da tradução: Fernando Martini aka fmartini © 2009