home *** CD-ROM | disk | FTP | other *** search
- #! /bin/sh
- # postinst script for gnome-power-manager
-
- set -e
-
- # Automatically added by dh_scrollkeeper
- if [ "$1" = "configure" ] && which scrollkeeper-update >/dev/null 2>&1; then
- scrollkeeper-update -q >/dev/null 2>&1
- fi
- # End automatically added section
- # Automatically added by dh_gconf
- if [ "$1" = "configure" ] && which update-gconf-defaults >/dev/null 2>&1; then
- update-gconf-defaults
- fi
- # End automatically added section
- # Automatically added by dh_gconf
- if [ "$1" = "configure" ]; then
- gconf-schemas --register gnome-power-manager.schemas
- fi
- # End automatically added section
- # Automatically added by dh_desktop
- if [ "$1" = "configure" ] && which update-desktop-database >/dev/null 2>&1 ; then
- update-desktop-database -q
- fi
- # End automatically added section
- # Automatically added by dh_iconcache
- touch -m /usr/share/icons/hicolor
- if [ "$1" = configure ] && \
- [ -x "`which gtk-update-icon-cache 2>/dev/null`" ] && \
- [ -f /etc/gtk-2.0/gdk-pixbuf.loaders ] && \
- [ "`find /usr/share/icons/hicolor -mindepth 1 -maxdepth 1 -type d | wc -l`" -gt 0 ] && \
- [ "`find /usr/share/icons/hicolor -mindepth 1 -maxdepth 1 -type f -name index.theme | wc -l`" -eq 1 ]; then
- gtk-update-icon-cache -q /usr/share/icons/hicolor
- fi
- # End automatically added section
-
-
- case "$1" in
- configure)
- if [ -r /usr/share/acpi-support/device-funcs ]; then
- . /usr/share/acpi-support/device-funcs
- DeviceConfig
- fi
- if [ "x$ACPI_SLEEP" = "xtrue" ]; then
- gconftool-2 --direct \
- --config-source xml:readwrite:/var/lib/gconf/defaults \
- --set --type bool \
- /apps/gnome-power-manager/can_suspend true
-
- gconftool-2 --direct \
- --config-source xml:readwrite:/var/lib/gconf/defaults \
- --set --type string \
- /apps/gnome-power-manager/action_button_suspend suspend
-
- gconftool-2 --direct \
- --config-source xml:readwrite:/var/lib/gconf/defaults \
- --set --type bool \
- /apps/gnome-power-manager/suppress_suspend_warning true
-
- fi
- ;;
-
- abort-upgrade|abort-remove|abort-deconfigure)
-
- ;;
-
- *)
- echo "postinst called with unknown argument \`$1'" >&2
- exit 1
- ;;
- esac
-
- exit 0
-