I learned an expensive lesson this week (expensive time-wise that is). If you have a Debian or Ubuntu-based distro, you have a command line option to clean up unused applications, including older versions of your current kernel if you have more than two of them. The command:
sudo apt autoremove
I used it mainly as a quick way to clean up old, unneeded kernels, as the five kernel packages take up almost a half gig of space. After awhile, I just used it automatically without looking at what it was going to remove. This time I got a nasty surprise, as among the packages it removed were a bunch of i386 packages needed by JMP (my old statistical program) and Microsoft Office 2010 running on Codeweaver's Crossover Linux. I spent about 2 hours getting those programs to run again, and it could have been worse had I not saved some notes about the i386 packages needed to install and run JMP.
The safer way to have done this would have been to look over the list of packages that would be deleted if you execute the autoremove command. (It lists those packages first and then gives you the option to execute the command or not.) The alternative would have been to use the Synaptic program and search for the packages you want to remove. For example, if you want to remove older versions of the 5.13 kernel packages, search for "5.13.0-" and you'll get a list of all packages meeting that description in your repositories, with those installed marked as such. You then have the option to remove them individually.
I suspect that there is a command line option that lets one remove a subset of the packages listed by the autoremove command, but I'm happy with the Synaptic option and haven't bothered to look this up.