summaryrefslogtreecommitdiffstats
path: root/helperscripts/find-orphans.sh
blob: d0fa3b661e86d2d72dca848c5ae3dadcfd9cdc72 (plain)
1
2
3
4
5
6
7
8
9
10
11
#!/bin/sh

for pkg in $(dpkg --get-selections |\
	     grep -Ee '[[:space:]]install$' |\
	     grep -Eoe '^[^[:space:]]+'); do
	if ! apt-cache showpkg "$pkg" |\
	     grep -q '/var/lib/apt/lists/'; then
	   	# Found an orphan. Print its name.
		echo "$pkg"
	fi
done
bues.ch cgit interface