Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
quick hack: How many "packages"....?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks
View previous topic :: View next topic  
Author Message
MaJor_PerMutation
n00b
n00b


Joined: 23 Jul 2003
Posts: 61

PostPosted: Sat Dec 06, 2003 1:40 pm    Post subject: quick hack: How many "packages"....? Reply with quote

I wondered if the "4000+" packages stated here would be quite actual...
...here a quick hack to count ebuilds and packages.

Code:

find /usr/portage/ -name *.ebuild | sort > /tmp/fes.lst
echo -n "Counted ebuilds: "
grep -c ".ebuild" /tmp/fes.lst
echo -n "Packages:     "
cat /tmp/fes.lst | sed -e s/-[0-9].*".ebuild"// | sort -u | wc -l
rm /tmp/fes.lst
Back to top
View user's profile Send private message
zhenlin
Veteran
Veteran


Joined: 09 Nov 2002
Posts: 1361

PostPosted: Sat Dec 06, 2003 2:17 pm    Post subject: Reply with quote

Code:
find /usr/portage -name '*.ebuild' | wc -l


Use the tools that are available. Don't overcomplicate things.

And... To make things more fun, time it. Then you know how nasty accessing a filesystem is.

Anyway... 11809 ebuilds.
Back to top
View user's profile Send private message
MaJor_PerMutation
n00b
n00b


Joined: 23 Jul 2003
Posts: 61

PostPosted: Sat Dec 06, 2003 2:48 pm    Post subject: Reply with quote

zhenlin wrote:
Use the tools that are available. Don't overcomplicate things.

And... To make things more fun, time it. Then you know how nasty accessing a filesystem is.


Maybe I misunderstand.
Which tool is available to show me how many Packages (not ebuilds) are available on my system? 8O

Code:

Counted ebuilds: 11798
Packages:        5816

real    0m5.227s
user    0m2.815s
sys     0m2.075s


(on Pentium-MMX, 233MHz, 128MB RAM, ReiserFS -noatime -notail (xfce4, xchat, Moz-FireBird, Sylpheed, Eterm)
Back to top
View user's profile Send private message
verbatim
Apprentice
Apprentice


Joined: 13 Mar 2003
Posts: 223

PostPosted: Sat Dec 06, 2003 4:04 pm    Post subject: Reply with quote

Code:
emerge gentoolkit
qpkg | wc -l


I got 5749. (a few less than above due to some rsync excludes)
Back to top
View user's profile Send private message
tomchuk
Guru
Guru


Joined: 23 Mar 2003
Posts: 317
Location: Brooklyn, NY

PostPosted: Sat Dec 06, 2003 7:01 pm    Post subject: Reply with quote

zhenlin wrote:
Code:
find /usr/portage -name '*.ebuild' | wc -l

Use the tools that are available. Don't overcomplicate things..


Speaking of using the tools that are available:

Code:

# emerge gentoolkit
thomas@dualie $ gentool-package-count
Number of categories : 104
Number of ebuilds    : 11807
Unique packages      : 5824


:P
Back to top
View user's profile Send private message
MaJor_PerMutation
n00b
n00b


Joined: 23 Jul 2003
Posts: 61

PostPosted: Sun Dec 07, 2003 8:05 am    Post subject: Reply with quote

*smashes head on keyboard*

I HAVE emerged gentoolkit...

...but I forget, which tools are 'in' it over and over again. :roll:

(I could use # etcat -f gentoolkit but it's typical linux recursion :lol:)

ok, sorry for posting unneccessary scripts, next time, I'll take a look at gentoolkit first.

:oops:
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Documentation, Tips & Tricks All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum