Sort installed rpms by decreasing size.

rpm -qa --qf "%-10{SIZE} %-30{NAME}\n" | sort -nr | less
It's all said in the title.
Sample Output
406081273  gcc-debuginfo                 
245120792  openoffice.org-core           
166575501  qt-doc                        
151034561  AdobeReader_enu               
112425640  texlive-texmf-fonts           
111882797  glibc-common                  
108660975  kernel                        
108517572  kernel                        
108498500  kernel                        
96831952   gutenprint-foomatic           
93285230   intel-iforte101021            
92981934   glibc-debuginfo               
87494563   VirtualBox-3.1                
86433623   compat-gcc-34-c++             
83807713   java-1.6.0-openjdk            
73147186   wine-core                     
65063553   libgcj                        
60059053   valgrind                      
59977177   wireshark                     
56262506   xorg-x11-drv-nvidia-libs      
53597279   google-chrome-beta            
52704734   thunderbird                   
49434288   qt-x11                        
48560661   jre                           
48202503   kdelibs                       
48041336   chromium-libs                 
47392883   openoffice.org-langpack-ja_JP 
46820236   qt-x11                        
46339569   gimp                          
44939255   kdelibs3                      
44228134   scribus                       
43433728   java-1.6.0-openjdk-devel      
42958608   boost-devel                   
41381019   evolution
[...]

2
2010-04-14 07:28:41

What do you think?

Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?

You must be signed in to comment.

What's this?

commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.

Share Your Commands



Stay in the loop…

Follow the Tweets.

Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.

» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10

Subscribe to the feeds.

Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):

Subscribe to the feed for: