Created
October 2, 2019 15:24
-
-
Save deviantintegral/0ae8b17f2cc3702037990110035ca6b6 to your computer and use it in GitHub Desktop.
A one-line script that finds installed Debian packages with no reverse dependencies, using multiple processes in parallel
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# This list may not be sorted, so if that is desired be sure to pipe the output through sort. | |
dpkg -l | \ | |
grep '^ii' | \ | |
awk '{ print $2 }' | \ | |
xargs -P4 -I, /bin/sh -c '[ "$(apt-cache rdepends --installed , | wc -l)" = "2" ] && echo ,' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment