When I refurb’d an old Lenovo as a Daily Desktop Driver I cloned Endeavour and another OS onto a newish SS with a preposterously small amt of room (180GB?) so each drive with swap is about 60GB, the boots and swap get the rest. Endeavour runs quite well on 60.
This means I have to be diligent about housecleaning and migrating music/movies/files to my external often.
Experiment was clean the Endeavour OS in two stages and observe how much crap gets eaten up.
Gparted was my measurement tool of choice.
Before cleaning: 33 GB used, 20GB unused.
After paccache, -Qtdq, vacuum journals, empty trash: 32 GB used, 21GB unused.
Basic Endeavour housekeeping commands got me 1GB back which is nice.
The I ran Maclean, written by our own @cscs . This cat invented The Terminator.
Post Maclean: 27GB used, 26GB unused.
Experiment results: in 20 minutes I was able to reclaim 6GB of space by purging un-necessary crap.
Righteous.
That script clears out caches. Caches are usually a tradeoff between e.g. a local storage and CPU cycles or waiting for network traffic. That isn’t un-necessary crap, it has a very specific purpose.
Maybe you prefer free disk space on your storage potato, which is fine, that doesn’t mean it’s a sane default consideration.
Not all functions of maclean are cache-related (logs, coredumps, orphans).
Of those, still, not all caches are created equal. Some caches may have been created by software no longer on the system or can otherwise simply be quite stale.
In the case of something like ~/.cache then a number of specific directories, like those used by browsers, are skipped and the default action also retains any paths accessed in the last 2 weeks on top of that.
I think the usefulness of caches, carte-blanche, is a little inflated here. As is the concept that ‘maclean just clears caches’ and whatever further conclusions are made from that assumption.
I auditioned about every single music player extra and yay had to offer so I brought in the debris that is for sure. (I even have Electron on here and don’t know why.) Mac is good for debris.
Orphans are in the responsibility of the user. Same for configuring coredump or logs retention too.
But they aren’t “unnecessary crap”. They serve a purpose. It’s just that the user decided to went down that particular road of manual intervention cleaning them.
( Well, aside from the “Flash” and “Pamac” and “Packagekit” and “pkgfile” things. And some things can become unnecessary crap - like something that is no longer installed or was only ever used to build something once in 2019. )
I also agree that some of these things have other possible configurable ways of keeping the cache/index/whatever at a certain level. Whether thats the Max for journal .. or even using systemd-tmpfiles for any various paths.
Agreed. I don’t want to throw a shadow on your script, it’s great to have easy control over the things going on in your system. I just wasn’t fully on board with the “un-necessary crap” characterization of OP.
That felt like a particular use case that script served, but not necessarily a desirable default.
there was a lot of debate about just this on a recent thread dedicated only to that tool (Maclean). I knew what I was getting into and I know what the results could be when it comes to caches. I am solely interested in space as a motivation.
Reckless? Possibly. I’ve noticed no changes when I use it; however I am not a power user.
EDIT:
perhaps I did not characterize this right. that is on me.
While I might be among the first to admit that such a utility is not strictly required .. especially for those who either have the technical know-how to set certain configs or just an undying love for typing out numerous different commandline invocations..
The main reason I made it was to be less dangerous than many of the popular alternatives (like Bleachbit).
as less dangerous bleachbit is an apt description. I will never use bleachbit. I’ve never read a happy user experience in all my years. They all start “guys I really messed up today.”
Not strictly required but I am a user who believes if offers value..everything after ‘strictly required’ describes me.