Easy cleaning of /var/cache/apt

view story

http://crunchbanglinux.org – Tired of removing programs and apt-get autoclean or apt-get autoremove doesn't wipe them all out? dpkg --get-selections|grep deinstall will show all the list of remaining .debs. That could be a long list of files to remove individually, so here's a script I got help with to do that all at once. Just enter this in your editor #!/bin/bash set -e for i in $(dpkg --get-selections| grep deinstall | awk '{ print $1 }'); do dpkg -P $i done exit 0 name it whatever you like and make it executable chmod +x filename and run it as sudo :) (HowTos)