On Fri, 2006-05-26 at 13:57 -0300, Rodrigo Barbosa wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > On Fri, May 26, 2006 at 12:35:40PM -0400, William L. Maltby wrote: > > <snip>Quick search in bout "man yum" and "man rpm" shows how to find what > > package X depends upon, but not what depends upon package X. Of course, > > we could get a deplist for everything but I'm *guessing* that take more > > overhead and grep too. > > > > "yum remove" tells us. Then we just have to remember to say "No, don't > > remove". Am I missing something... like I missed that big Google box on > > the archives? > > > > Anyway, if I haven't overlooked something, I was thinking that this > > might be a good enhancement request for yum's buglist. Do like remove > > but skip making us reliably answer "no". > > > > OK. Did I miss something? Is this a feature that others would find > > handy? Should I get it on a yum bug list? > > Just needs a little magic: > > rpm -q --provides PACKAGE_NAME | sed 's/^/"/;s/\([^[:space:]]\) *$/\1"/' | xargs rpm -q --whatrequires | grep -v -E '^no package' > > ex: > rpm -q --provides exim | sed 's/^/"/;s/\([^[:space:]]\) *$/\1"/' | xargs rpm -q --whatrequires | grep -v -E '^no package' LOL! Being an old CLI-oriented fart, your regex is perfectly clear to me. But, being an old CLI-oriented fart, I am now lazy, having earned a big rest for having learned regex et al back when there was no choice. One nice thing about this list, a post like yours doesn't have all the Perl folks jumping in with their "bigger/better" like they did on LFS. In the spirit of good fun, I challenge you to enter that reliably (no cheating and putting it into a script) after a 14 hour day of dealing with the PHBs! =>:-O Also, why don't you run that and do a time command and see if the overhead is reasonable. Using cyrus-sasl should be good. I'll run a time on a yum remove of cyrus-sasl here... real 0m30.548s user 0m13.005s sys 0m1.401s This on my AMD PR-2200 Athlon 3/4 GB DDR 2700 ram. Didn't clean any cache first, so benefited from the recent experiments some. > <snip> -- Bill -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 189 bytes Desc: This is a digitally signed message part URL: <http://lists.centos.org/pipermail/centos/attachments/20060526/40d97522/attachment-0005.sig>