Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 28 Sep 2017 17:34:05 +0200
From:      Luca Pizzamiglio <pizzamig@freebsd.org>
To:        Mel Pilgrim <list_freebsd@bluerosetech.com>
Cc:        freebsd-pkg@freebsd.org
Subject:   Re: Get list of packages installed from a given repo
Message-ID:  <CAB88xy8%2BfiCJDvLgJ9jwYGr_RDDEVy2GNs=1Ssieqf_cDD7MDw@mail.gmail.com>
In-Reply-To: <369a094a-f6c6-9829-0fba-eb34c5ea9579@bluerosetech.com>
References:  <369a094a-f6c6-9829-0fba-eb34c5ea9579@bluerosetech.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi Mel,

the %R keyword is available in the query format, but is not available
in the evaluation.

you can use something like that:

# pkg query "%R %o" | grep -v ^FreeBSD
# pkg query "%R %o" | grep ^local

Best regards,
pizzamig

On Sun, Sep 17, 2017 at 8:33 PM, Mel Pilgrim
<list_freebsd@bluerosetech.com> wrote:
> I maintain local repos on top of the public pkg repo, and I want to check
> which pkgs were installed from which repos.  I know pkg knows this
> information (the %R query keyword), but this doesn't work:
>
> # pkg query -e '%R !~ FreeBSD' %o
> malformed evaluation string
> # pkg query -e '%R ~ local' %o
> malformed evaluation string
>
> How do I query for a list of installed pkgs based on an evaluation of the
> repo name?
> _______________________________________________
> freebsd-pkg@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-pkg
> To unsubscribe, send any mail to "freebsd-pkg-unsubscribe@freebsd.org"



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAB88xy8%2BfiCJDvLgJ9jwYGr_RDDEVy2GNs=1Ssieqf_cDD7MDw>