%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /var/lib/dpkg/info/
Upload File :
Create Path :
Current File : /var/lib/dpkg/info/slim.config

#! /bin/sh
# Debian slim package configuration script
# Copyright 2007 Darren Salt
# Licensed under the GNU General Public License, version 2.  See the file
# /usr/share/common-licenses/GPL or <http://www.gnu.org/copyleft/gpl.txt>.

# adapted from xdm's config script
# Debian xdm package configuration script
# Copyright 2000-2003 Branden Robinson.

set -e

# source debconf library
. /usr/share/debconf/confmodule

# set default display manager
DEFAULT_DISPLAY_MANAGER_FILE=/etc/X11/default-display-manager

OWNERS=
if db_metaget shared/default-x-display-manager owners; then
  OWNERS="$RET"
fi

CHOICES=
if db_metaget shared/default-x-display-manager choices; then
  CHOICES="$RET"
fi

if [ "$OWNERS" != "$CHOICES" ]; then
  db_subst shared/default-x-display-manager choices "$OWNERS" || :
  db_fset shared/default-x-display-manager seen false || :
fi

# debconf is not a registry; use the current contents of the default display
# manager file to pre-answer the question if possible
if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ]; then
  CURRENT_DEFAULT=$(basename "$(grep -v '^[[:space:]]*#' \
                                "$DEFAULT_DISPLAY_MANAGER_FILE" |
                                head -n 1)")
  if [ -n "$CURRENT_DEFAULT" ]; then
    db_set shared/default-x-display-manager "$CURRENT_DEFAULT"
  fi
else
  CURRENT_DEFAULT=
  if db_get shared/default-x-display-manager; then
    CURRENT_DEFAULT="$RET"
  fi
fi

db_input high shared/default-x-display-manager || :
db_go || :

# using this display manager?
NEW_DEFAULT=
if db_get shared/default-x-display-manager; then
  NEW_DEFAULT="$RET"
fi

# move the default display manager file if we're going to change it
if [ -n "$NEW_DEFAULT" ]; then
  if [ "$NEW_DEFAULT" != "$CURRENT_DEFAULT" ]; then
    if [ -e "$DEFAULT_DISPLAY_MANAGER_FILE" ]; then
      mv "$DEFAULT_DISPLAY_MANAGER_FILE" \
         "$DEFAULT_DISPLAY_MANAGER_FILE.dpkg-tmp"
    fi
  fi
fi

Zerion Mini Shell 1.0