cleaning up arch from the terminal

i use bleachbit and stacer but as one cleans things the other doesn't for example stacer will clean all logs that bleachbit wont and bleachbit will clean out yor terminal commands that stacer wont and ill use bleachbit first and there will still be cache in cookies in stacer which makes no sense

so i would appreciate if i could get the commands that will clean out all Package caches,Aplication caches,Application logs and journactl and crash report logs

i know

sudo pacman -Scc cleans ALL application caches

rm -rf ~/.cache/* cleans cache in your home directory

sudo pacman -Rsn $(pacman -Qdtq) still dont know the difference between this and the one below

sudo pacman -Rns $(pacman -Qtdq) cleans orphanes
sudo pacman -Rscnd removes the program and its optional dependencies

  1. Don't use BleachBit: it causes more trouble than it's worth. (100% personal and subjective opinion, feel free to disregard)

  2. I use this to keep my system "clean" about once per month:

    #Remove orphans
    pamac remove --orphans
    #clean cache
    pamac clean --keep 2
    pamac clean --build-files
    #clean Journals
    sudo journalctl --vacuum-time=14d

Same here do not use BleachBit.

1 Like

You can delete cache in your home time to time, I often clean dotfiles of programs what I do not use anymore, not for space saving just for better orientation there.
If you have arch and not pamac installed you probably have yay so use yay -Yc

i dont use pamac at all

Well, it's the Manjaro standard, so why not give it a try???


@Fabby he has Arch

i have read all but maybe i missed a thingplus i have made a timer with pacache to clean pacman and journalctl up everytime i run pacman

at the end of that article there is link to forum topic about automatic cleaning and there is link to this package, I did not try

anyway this topic should be moved to another OS. I can do it but more experienced user should do it. Even thought here are good recommendations, I do not know.

1 Like

thank you very much

yea i wouldnt mind if you moved it

The archway would be:
sudo pacman -Rns $(pacman -Qdtq)
I'm trying to learn pacman commands more and more and use them instead of pamac.
I've had had issues with pamac in the past, breaking the system etc. Never had the problem with pacman so far.

Forum kindly sponsored by