summaryrefslogtreecommitdiff
path: root/init.d/60create-packagelist
blob: 351d5aaf0bf88a4651a8b149866a1db54103dce3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
#!/bin/sh
set -e

# 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