[plug] Request

Matt Kemner zombie at networx.net.au
Wed Mar 1 17:08:54 WST 2000


On Wed, 1 Mar 2000, Anthony J. Breeds-Taurima wrote:

> cd path/to/RPMS
> for i in *.rpm ; do
> 	echo ...
> 	rpm -ql $i 2>&1 | grep $1
> 	echo $i
> done
> 
> then you'll get a complete list of rpms BUT if you see the files your
> intersted in then the NEXT rpm is the one that contains them.

A better way would be to replace the rpm line with

	rpm -ql $i 2>&1 | grep -q $1 && echo $i

and get rid of the echo $i on the next line.. that way the only output
you'll see is the name of the rpm containing $1

 - Matt




More information about the plug mailing list