freebsd / pkg

Package management tool for FreeBSD. Help at #pkg on Libera Chat or pkg@FreeBSD.org
Other
748 stars 280 forks source link

pkg query -e "%q~string" does not match #1554

Closed lonkamikaze closed 7 years ago

lonkamikaze commented 7 years ago

pkg query -e "%q~freebsd:10:*" "%q %o" lists no packages. pkg query "%q %o" | grep '^freebsd:10:' lists 286.

pkg query -e "%q~freebsd:10:x86:64" "%q %o" lists no packages. pkg query "%q %o" | grep '^freebsd:10:x86:64 lists 280.

# pkg info pkg
pkg-1.10.0_2
Name           : pkg
Version        : 1.10.0_2
Installed on   : Mon Feb 27 19:08:02 2017 CET
Origin         : ports-mgmt/pkg
Architecture   : freebsd:11:x86:64
Prefix         : /usr/local
…
# uname -a
FreeBSD AprilRyan.norad 11.0-STABLE FreeBSD 11.0-STABLE #5 r315554: Sun Mar 19 16:38:27 CET 2017     root@AprilRyan.norad:/usr/obj/S403/amd64/usr/src/sys/S403  amd64   
bapt commented 7 years ago

Actually you are not supposed to see freebsd:11:x86:64 but FreeBSD:11:amd64, in this case pkg query works I'm fixing the result of %q

bapt commented 7 years ago

fixed should now be pkg query -e "%q ~ FreeBSD:10:*" "%q %o"