[BBLISA] List packages that are not dependencies

Mark Lamourine markllama at gmail.com
Tue Oct 11 14:40:14 EDT 2011


for RPM in `rpm -qa --qf "%{NAME}\n" | sort -u` ; do
  if [ "`rpm -q --whatrequires $RPM`" == "no package requires $RPM" ] ;
then
    echo "$RPM"
  fi
done

On Tue, Oct 11, 2011 at 2:22 PM, Alex Aminoff <alex at basespace.net> wrote:

>
> This is surprisingly more difficult than I expected.
>
> Is there a simple way to ask a package management system (rpm, yum, or
> apt) to list those packages which are not themselves dependencies for
> any other package?
>
> I could ask for the dependencies of each package and then write perl
> code to figure it out, but I don't think I should have to.
>
>  - Alex Aminoff
>    BaseSpace.net
>
>
> _______________________________________________
> bblisa mailing list
> bblisa at bblisa.org
> http://www.bblisa.org/mailman/listinfo/bblisa
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.bblisa.org/pipermail/bblisa/attachments/20111011/184760a2/attachment.html 


More information about the bblisa mailing list