]>
git.saurik.com Git - apt.git/blob - dselect/update
4 # Set the textdomain for the translations using $"..."
7 # Get the configuration from /etc/apt/apt.conf
10 APTGET
="/usr/bin/apt-get"
11 APTCACHE
="/usr/bin/apt-cache"
13 DPKG_OPTS
="--admindir=$1"
14 APT_OPT0
="-oDir::State::status=$1/status"
15 APT_OPT1
="-oDPkg::Options::=$DPKG_OPTS"
16 CACHEDIR
="/var/cache/apt"
18 RES
=`apt-config shell CLEAN DSelect::Clean OPTS DSelect::UpdateOptions \
19 DPKG Dir::Bin::dpkg/f APTGET Dir::Bin::apt-get/f \
20 APTCACHE Dir::Bin::apt-cache/f CACHEDIR Dir::Cache/d \
21 PROMPT DSelect::PromptAfterUpdate/b`
24 # It looks slightly ugly to have a double / in the dpkg output
25 CACHEDIR
=`echo $CACHEDIR | sed -e "s|/$||"`
28 if $APTGET $OPTS "$APT_OPT0" "$APT_OPT1" update
30 echo $
"Merging Available information"
31 rm -f $CACHEDIR/available
32 $APTCACHE dumpavail
> $CACHEDIR/available
33 $DPKG "$DPKG_OPTS" --update-avail $CACHEDIR/available
34 rm -f $CACHEDIR/available
37 Pre
-Auto|PreAuto
|pre
-auto)
38 $APTGET "$APT_OPT0" "$APT_OPT1" autoclean
;;
44 if [ x
$PROMPT = "xtrue" ]; then
45 echo $
"Press enter to continue." && read RES
;