From owner-freebsd-pkg@FreeBSD.ORG Mon Mar 4 13:08:28 2013 Return-Path: Delivered-To: freebsd-pkg@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 196EE62B for ; Mon, 4 Mar 2013 13:08:28 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from smtp.infracaninophile.co.uk (smtp6.infracaninophile.co.uk [IPv6:2001:8b0:151:1:3cd3:cd67:fafa:3d78]) by mx1.freebsd.org (Postfix) with ESMTP id A2E581773 for ; Mon, 4 Mar 2013 13:08:27 +0000 (UTC) Received: from rufus.webfusion.com (mail.heartinternet.co.uk [79.170.40.31]) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.14.6/8.14.6) with ESMTP id r24D8ABT009821 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO) for ; Mon, 4 Mar 2013 13:08:17 GMT (envelope-from m.seaman@infracaninophile.co.uk) DKIM-Filter: OpenDKIM Filter v2.8.0 smtp.infracaninophile.co.uk r24D8ABT009821 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=infracaninophile.co.uk; s=201001-infracaninophile; t=1362402497; bh=4CmFcT96muAxR3+SGRHAju/rm80BisWj8JFhWrMIuNs=; h=Date:From:To:Subject:References:In-Reply-To; z=Date:=20Mon,=2004=20Mar=202013=2013:08:09=20+0000|From:=20Matthew =20Seaman=20|To:=20freebsd-pkg@fr eebsd.org|Subject:=20Re:=20pkgng=20info=20command:=20-d=20override s=20-r?|References:=20<51347590.4090201@bluerosetech.com>=20<20130 304114037.GJ64570@ithaqua.etoilebsd.net>|In-Reply-To:=20<201303041 14037.GJ64570@ithaqua.etoilebsd.net>; b=Q4ZsSsnTE39BplW5krIBkrVvMu5ly8E+w/zJpIQhoTomdzHV9A//MhtGdU6KQ63gK /00WezXyTzKI/N7xTnLJSxFzDIDnwHDuX/AH32RAoszsZ4whH+6HkhgLgRdlo7arZC Sm3JcMrEItnEGZlKnOA8zfyCYqOrapWvo3e13xJ4= X-Authentication-Warning: lucid-nonsense.infracaninophile.co.uk: Host mail.heartinternet.co.uk [79.170.40.31] claimed to be rufus.webfusion.com Message-ID: <51349CB9.4090004@infracaninophile.co.uk> Date: Mon, 04 Mar 2013 13:08:09 +0000 From: Matthew Seaman Organization: Infracaninophile User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:17.0) Gecko/20130220 Thunderbird/17.0.3 MIME-Version: 1.0 To: freebsd-pkg@freebsd.org Subject: Re: pkgng info command: -d overrides -r? References: <51347590.4090201@bluerosetech.com> <20130304114037.GJ64570@ithaqua.etoilebsd.net> In-Reply-To: <20130304114037.GJ64570@ithaqua.etoilebsd.net> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: clamav-milter 0.97.6 at lucid-nonsense.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_FAIL autolearn=no version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on lucid-nonsense.infracaninophile.co.uk X-BeenThere: freebsd-pkg@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Binary package management and package tools discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 04 Mar 2013 13:08:28 -0000 On 04/03/2013 11:40, Baptiste Daroussin wrote: > CCed to pkg@FreeBSD.org where the discussion deserves to be :) > > On Mon, Mar 04, 2013 at 02:21:04AM -0800, Darren Pilgrim wrote: >> With pkg_info, I can get a list of ports requiring and depended on by a >> given port by doing `pkg_info -rR`. In pkgNG, the equivalent would be >> `pkg info -dr`, but there appears to be a problem giving -d and -r at >> the same time. For example: >> >> # pkg info -r postgresql-client-9.2.3 >> postgresql-client-9.2.3 is required by: >> postgresql-server-9.2.3 >> >> # pkg info -d postgresql-client-9.2.3 >> postgresql-client-9.2.3 depends on: >> pkgconf-0.8.9 >> libiconv-1.14 >> libxml2-2.7.8_5 >> gettext-0.18.1.1 >> >> So the output of -dr should be something like this: >> # pkg info -dr postgresql-client-9.2.3 >> postgresql-client-9.2.3 depends on: >> pkgconf-0.8.9 >> libiconv-1.14 >> libxml2-2.7.8_5 >> gettext-0.18.1.1 >> postgresql-client-9.2.3 is required by: >> postgresql-server-9.2.3 >> >> But instead I get this: >> >> # pkg info -dr postgresql-client-9.2.3 >> postgresql-client-9.2.3 depends on: >> pkgconf-0.8.9 >> libiconv-1.14 >> libxml2-2.7.8_5 >> gettext-0.18.1.1 >> >> # pkg info -rd postgresql-client-9.2.3 >> postgresql-client-9.2.3 depends on: >> pkgconf-0.8.9 >> libiconv-1.14 >> libxml2-2.7.8_5 >> gettext-0.18.1.1 >> >> It looks like pkg ignores -r if -d is given, but the two shouldn't be >> exclusive. Am I missing something? > > No you are missing nothing in fact we haven't handled yet options multual > exclusion. > > I haven't thought that anyway one will do a pkg info -rd so I didn't test what > could be happening here :) > > thanks for reporting, definitly something to work on, don't know yet what should > be done here: > either say "hey you can't pass -r and -d at the same time" which would be the > easy fix :) or output things like you suggested which will be less easy Actually, making pkg info show both should be pretty easy. It's the same function for generating the output as used by pkg search and that definitely can show any arbitrary combinations of data about packages. You just pass it a bitmap telling it what you want to print out. Or is that only in the 1.1 code? I've lost track. Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. PGP: http://www.infracaninophile.co.uk/pgpkey JID: matthew@infracaninophile.co.uk