summaryrefslogtreecommitdiff
path: root/dselect/update
diff options
context:
space:
mode:
authorArch Librarian <arch@canonical.com>2004-09-20 16:51:33 +0000
committerArch Librarian <arch@canonical.com>2004-09-20 16:51:33 +0000
commit7a1b1f8bd649113e99ecef0489e2f2194e283d1e (patch)
tree753f89e873612294a9a5a782294ebc2bf1c65462 /dselect/update
parent30e1eab53324523297a24c18819b27aba7ce1fb4 (diff)
Dselect support
Author: jgg Date: 1998-11-22 23:37:03 GMT Dselect support
Diffstat (limited to 'dselect/update')
-rwxr-xr-xdselect/update22
1 files changed, 22 insertions, 0 deletions
diff --git a/dselect/update b/dselect/update
new file mode 100755
index 000000000..ca507c4c6
--- /dev/null
+++ b/dselect/update
@@ -0,0 +1,22 @@
+#!/bin/sh
+set -e
+
+# Get the configuration from /etc/apt/apt.conf
+OPTS="-f"
+APTGET="/usr/bin/apt-get"
+APTCACHE="/usr/bin/apt-cache"
+DPKG="/usr/bin/dpkg"
+CACHEDIR="/var/cache/apt"
+RES=`apt-config shell OPTS DSelect::UpdateOptions \
+ DPKG Dir::Bin::dpkg APTGET Dir::Bin::apt-get \
+ APTCACHE Dir::Bin::apt-cache CACHEDIR Dir::Cache`
+eval $RES
+
+$APTGET $OPTS update
+
+echo "Merging Available information"
+rm -f /var/cache/apt/available
+$APTCACHE dumpavail > $CACHEDIR/available
+$DPKG --update-avail $CACHEDIR/available
+rm -f $CACHEDIR/available
+exit 0