summaryrefslogtreecommitdiff
path: root/init.d
diff options
context:
space:
mode:
authorScott Bronson <b.git@u32.net>2008-03-12 16:30:41 -0700
committerScott Bronson <b.git@u32.net>2008-03-12 16:30:41 -0700
commit2d0f02f740f73bafba187584184ec26fdf1cc3aa (patch)
tree2553186124999163bd66f4b44adce96735d71fae /init.d
parentd2a3a0b04c727430ece08aa4ec0e7719fa037f98 (diff)
Add support for RPM (note: untested!)
Diffstat (limited to 'init.d')
-rwxr-xr-xinit.d/60create-packagelist13
1 files changed, 11 insertions, 2 deletions
diff --git a/init.d/60create-packagelist b/init.d/60create-packagelist
index ccac425..351d5aa 100755
--- a/init.d/60create-packagelist
+++ b/init.d/60create-packagelist
@@ -1,5 +1,14 @@
#!/bin/sh
set -e
-# The output is already sorted
-dpkg-query --show > /etc/package-list
+# NOTE: the output of this command should always be emtpy!
+# diff init.d/60create-packagelist post-install.d/10update-packagelist
+# todo: fix this with symlinks? Or with metadata.d?
+
+if [ "$LOWLEVEL_PACKAGE_MANAGER" = dpkg ]; then
+ # The output is already sorted
+ dpkg-query --show > /etc/package-list
+elif [ "$LOWLEVEL_PACKAGE_MANAGER" = "rpm" ]; then
+ rpm -qa | sort > /etc/package-list
+fi
+