How to list explicitly installed packages but not by calamares?

Hi.

So I was wondering, how do I search and isolate all the installed packages that I singlehandedly installed by pacman -S without showing the ones that were installed by calamares ?

I already tried pacman -Qm that lists AUR packages, which is working fine.

The pacman -Qe lists all explicitly installed packages, from the arch and/or eos repos, but at the same time it lists all the packages that were installed by calamares when I installed eos.

Is there a proper way, to list only the truly manually installed packages (and still residing installed on the system), and if yes, how?

If your install is new, you can exclude all the packages on ISO by pulling the list from the pacstrap module and eos-packagelist.

If your install is older there isn’t a fully reliable way.

You can back through your pacman logs if you don’t rotate them and try to find the packages installed during the install process.

However you do it, once you get the lists, you can use comm to work the lists down to what you need.

1 Like

Thanks. My install is like 1week old.

I haven’t touched my install, all I see that there’s a logrotate timer, so I guess its gonna rotate itself automatically in time, afaik, it only gets archived, but never gets deleted (correct me if I’m wrong)

eos-packagelist I gotcha what you mean :slight_smile: However “pacstrap”, “module”, “pulling”, “ISO” keywords - confused face :smiley: I’m not that professional in linux, can you elaborate plase?
I haven’t found any pacstrap entry, isn’t that an arch thingie? (based on archwiki + I remember this one back when I tried installing arch, like a year ago, with great success but neve again xD )

Yes btw, until now I was doing this grep -i <packagename> /var/log/pacman.log but its too long to always do that + I always gotta find for its “pair” if I already removed it or is it still installed. What I’m trying to achieve, is to have a fresh knowledge of my installed softwares, that I can manage if I no longer need (and some of them doesn’t appear on the menu).

comm I heard this one before, but I got no idea what could I do with it. Can you elaborate this step aswell?

I know for bash you could check your bash history file for the pacman commands you did manually this should help you narrow the list i would think.

1 Like

Thanks, yepp totally forgot to mention that I also do this occasionally:
history | grep "pacman -S "
But then I told myself, there has to be a more professional way, but it seems only this DIY hacking methods are the only viable one then :smiley:

Yesterday I had literally same task (my install is almost 1.5 y.o.) and this post, as well as overall thread were very helpful.

My steps:

  • with this command I got all explicitly installed packages (including those installed from the ISO):
    pacman -Qqe
  • this one listed all packages installed prior to the creation of user’s home directory:
    paclog --before="$(stat ~ | grep "Birth" | cut -d " " -f 3,4)" | grep "installed" | cut -d " " -f 4 | sort | uniq
  • with the help of meld, I just compared 2 list files and removed from first one everything installed by ISO

Result was pretty accurate, so for me it did the job

1 Like

This! Perfect - works like a dream, thank you @firefly , literally this was the solution I was looking for, very well detailed step by step guide, much appreciated.

Only thing I had to tweak is the “Birth” keyword, because it’s locale dependent, I had to change it to my language (hungarian “Születés”) and it worked, so others finding this post, using non-english system, have to change the “Birth” to their language (stat filename and you’ll see yours)

Extra for edit:
Made a one liner inspired from your meld approach, but using git diff instead :slight_smile:

paclog --before="$(stat ~ | grep "Birth" | cut -d " " -f 3,4)" | grep "installed" | cut -d " " -f 4 | sort | uniq > A && pacman -Qqe > B ; git diff A B | grep ^+ ; rm A B

Also made an alias within my .zshrc / .bashrc alias sl= and the above command, so it’s easier to call. (sl = as in softwarelist)

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.