How to search multiple keywords in yum shell?

General support questions including new installations

How to search multiple keywords in yum shell?

Postby taolei » 2009/01/03 02:30:14

Hello.

In yum shell, command "search abc xyz" will return packages containing "abc" OR "xyz".
How to search packages containing "abc" AND "xyz" ?

Thanks.
taolei
 
Posts: 116
Joined: 2007/05/01 02:47:32

Re: How to search multiple keywords in yum shell?

Postby NedSlider » 2009/01/03 12:32:56

I don't believe that's possible.

What you can do is pipe the output to grep, but it's not the same:

Code: Select all
yum search abc | grep xyz


or use list with wildcards if you know package names:

Code: Select all
yum list *gnome*devel*


will find all packages with gnome followed by devel in the name. Again, it's not the same as an AND operator as it won't find "devel" followed by "gnome", and it's only operating on package names.
NedSlider
Forum Moderator
 
Posts: 2872
Joined: 2005/10/28 13:11:50
Location: UK


Return to CentOS 5 - General Support

Who is online

Users browsing this forum: No registered users and 2 guests