Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - General
User Name
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.


  Search this Thread
Old 02-27-2010, 09:48 AM   #1
LQ Newbie
Registered: Feb 2010
Posts: 2

Rep: Reputation: 0
Question Using rpm command to count the numbers of license.....

I am a newbie in Linux

Here is my question....
Create the file ~/license_counts, which tables the number of occurrences of packages which are licensed under a given license, for the top 5 most commonly used licenses, sorted in numerically descending order. If performed correctly, your file should be formatted similarly to the following. (Do not be concerned if the actual counts or license names are different. Also, you might notice logically similar licenses, such as LGPL/GPL and GPL/LGPL. Do not make any attempt to combine them into a single entry.)

The resulted format:
[prince@station prince]$ cat license_counts
355 GPL
147 LGPL
53 BSD
47 distributable
18 xorg

any way to do this? i tried some method but cannot get it to work.
Thank You.
Old 02-27-2010, 10:14 AM   #2
Senior Member
Registered: Jul 2005
Distribution: Slackware
Posts: 2,014

Rep: Reputation: 115Reputation: 115
Sounds like homework.

Tell us what you've already tried, and ask specific questions about the stuff you don't know about.
Old 02-27-2010, 11:50 AM   #3
Senior Member
Registered: Jun 2005
Location: England
Distribution: openSUSE, Fedora, CentOS
Posts: 1,093

Rep: Reputation: 197Reputation: 197


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Using rpm command to count the numbers of license..... toshitaka Linux - Newbie 2 02-28-2010 07:55 PM
LXer: Why Folks Didn't Want a SCOsource License: Let Us Count the Reasons LXer Syndicated Linux News 0 02-22-2010 10:30 AM
Need help in word count command grunge_1 Linux - General 4 03-20-2009 04:01 AM
How can I get the rpm command and rpm build command on my Debian box? abefroman Debian 6 11-28-2005 12:38 PM
How to count line numbers recursively in a directory? puzz_1 Linux - General 1 07-01-2004 09:43 AM > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:09 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration