pkg search dependency tree

Sergey Akhmatov sergey at akhmatov.ru
Sun Jan 14 20:00:09 UTC 2018


> I got off-list reply on how to achieve this with locally installed
> packages, by using `pkg prime-origins', which is apparently an alias to
> the command you suggested.
>
> It will solve my problem, as I have no more than 20 servers using this
> repo, I just need to run the command on all of them and uniq the output.
>
> But it would be nice if I could do this for all the packages in repo,
> and not just for packages installed locally on each server.
You could use  "pkg rquery", which handles requests agains remote repo 
database.
It features less request types than "pkg query" against local packages 
database,
but I hope it could give some help for you problem. E.g. you could use:
% pkg rquery '%o - %?r'
to get list of packages with a number of reverse dependencies and 
consider the ones with zero
reverse dependencies as 'top level'.
'man pkg-rquery' may give some other hints.




More information about the freebsd-ports mailing list