I know I have some packages ready to be removed if I run apt-get autoremove, but I just want to know which they are, without removing them. How can I list what would be removed without removing them? Alternatively, how can I run the above command and force it to prompt me?
Asked
Active
Viewed 4,475 times
9
akraut
- 311
Luca Borrione
- 775
1 Answers
11
The autoremove function lists the packages to be removed and asks for permission to continue before actually carrying out the operation. If you just want to see what would happen
You can use the -s or --simulate... switches to perform no actions
-s, --simulate, --just-print, --dry-run, --recon, --no-act
No action; perform a simulation of events that would occur but do not actually change the system.
so
apt-get -s autoremove
should do what you want. There is a --assume-no switch that can be used to force no to any questions asked too e.g.
apt-get autoremove --assume-no
The autoremove function only removes packages that are no-longer needed so you should be safe to run it anyway.
autoremove
autoremove is used to remove packages that were automatically installed to satisfy dependencies for other packages and are now no longer needed.
user9517
- 116,228