View previous topic :: View next topic |
Author |
Message |
mitchy n00b
Joined: 27 Sep 2007 Posts: 46 Location: Rochester, MN
|
Posted: Tue Oct 09, 2007 3:47 pm Post subject: Displaying the contents of 'world' |
|
|
I'm almost finished setting up all the software and utilities I need to replace my Windows box. I know I've emerged a few things along the way that I no longer need now. However, I'm having trouble finding out what I currently have in my world file. I saw in the emerge man page that I can do this to view the file directly:
Code: | cat /var/lib/portage/world |
That basically gets me the info I want, but I assume there has to be a better way. I'm also interested in seeing the exact version of each package that I have in my world file (and possibly their dependencies). Is there a better command out there that anyone can recommend? I'm also interested in seeing what is in system as well. Thanks in advance! _________________ "I got a fever! And the only prescription...is more cowbell!" ~ Christopher Walken |
|
Back to top |
|
|
PaulBredbury Watchman
Joined: 14 Jul 2005 Posts: 7310
|
Posted: Tue Oct 09, 2007 3:49 pm Post subject: |
|
|
Portage's definition of "world" is not necessarily all installed packages. E.g.:
Code: | emerge -p --depclean |
Last edited by PaulBredbury on Tue Oct 09, 2007 3:50 pm; edited 1 time in total |
|
Back to top |
|
|
bmichaelsen Veteran
Joined: 17 Nov 2002 Posts: 1277 Location: Hamburg, Germany
|
Posted: Tue Oct 09, 2007 3:49 pm Post subject: |
|
|
maybe you want
Code: | emerge -epDt world
emerge -epDt system
|
|
|
Back to top |
|
|
mitchy n00b
Joined: 27 Sep 2007 Posts: 46 Location: Rochester, MN
|
Posted: Tue Oct 09, 2007 4:03 pm Post subject: |
|
|
Right, from what I understand....
system - is everything required to have a base Gentoo system
world - is everything that I specifically ask to have emerged + system (not including any dependencies)
So I think "emerge -epv world" will give me what I want. I just need to filter through to see which were ones I emerged and which were dependencies. Same would go for the "emerge -epv system".
I think I could combine the /etc/lib/portage/world file with the contents of the above emerge using grep to get a list of just the world packages that I'm interested in, but I can't quite get the formatting correct. Guessing it's something like this (but it doesn't work).
Code: |
emerge -epv world | grep cat /etc/lib/portage/world
|
Any thoughts? _________________ "I got a fever! And the only prescription...is more cowbell!" ~ Christopher Walken |
|
Back to top |
|
|
tarpman Veteran
Joined: 04 Nov 2004 Posts: 1083 Location: Victoria, BC, Canada
|
Posted: Wed Oct 10, 2007 5:34 pm Post subject: |
|
|
What exactly are you looking for? /var/lib/portage/world contains every package you've explicitly emerged, with SLOT if you explicitly chose a particular slot.
To see what version you have of each package in your world file, you could do something like:
Code: | while read pkg ; do equery l -i ${pkg} | tail -n 1 ; done < /var/lib/portage/world |
but I don't see how versions are relevant; in the vast majority of cases you want the latest available anyway. _________________ Saving the world, one kilobyte at a time. |
|
Back to top |
|
|
ppurka Advocate
Joined: 26 Dec 2004 Posts: 3256
|
Posted: Wed Oct 10, 2007 5:52 pm Post subject: |
|
|
for a sorted list of installed packages. However, bmichaelsen's solution will give you a better view of the dependencies. _________________ emerge --quiet redefined | E17 vids: I, II | Now using kde5 | e is unstable :-/ |
|
Back to top |
|
|
mitchy n00b
Joined: 27 Sep 2007 Posts: 46 Location: Rochester, MN
|
Posted: Thu Oct 11, 2007 1:05 pm Post subject: |
|
|
Thanks everyone - the reason for wanting to know specific versions of packages is more out of curiosity. Just trying to learn how portage works, etc. I'll have to try out the eix package and see how that works as well. _________________ "I got a fever! And the only prescription...is more cowbell!" ~ Christopher Walken |
|
Back to top |
|
|
BlackEdder Advocate
Joined: 26 Apr 2004 Posts: 2588 Location: Dutch enclave in Egham, UK
|
Posted: Thu Oct 11, 2007 1:11 pm Post subject: |
|
|
Did you try the -t switch, as suggested by bmichaelsen, to get a tree view, with the top level the packages in your world file?
|
|
Back to top |
|
|
mitchy n00b
Joined: 27 Sep 2007 Posts: 46 Location: Rochester, MN
|
Posted: Thu Oct 11, 2007 1:18 pm Post subject: |
|
|
Yes, I did use the -t flag as suggested. I gives a nice view for viewing everything including dependencies, which would also come in handy I think. _________________ "I got a fever! And the only prescription...is more cowbell!" ~ Christopher Walken |
|
Back to top |
|
|
|