From nobody Tue Aug 15 13:33:54 2023 X-Original-To: freebsd-pkg@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RQC0N006Hz4mPfg for ; Tue, 15 Aug 2023 13:33:56 +0000 (UTC) (envelope-from se@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RQC0M6Yxwz4F1G; Tue, 15 Aug 2023 13:33:55 +0000 (UTC) (envelope-from se@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692106435; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+/AQq+p6PLYRselyWhAIq+mJ7duwc6J/7QRyh20GWGg=; b=Y5/RCyxC7vh8hj5bxN51DB2dFHCiXPJ6+xYLjVBnJi2Wkb0pBInwLbhcseub2X1XU9ZVNX X1sCz1bMy1fMczxPGMdX+sxt1T1tp8mgpoYdDNy+buJk93u8tqiE/MKGByhFqdPiZDtcO4 0Cex3aF2SdLDHkEinOdPdcJPey37qc9GdvX/+dSsJA1KsnuPh5Hu6U7/TfCuGx0nG62I73 nk+42iMhngt0XVr34x5CPQw5z70drqa1WAdSuZV7uMyFJozTSSiffHYghMqq+f03wdA2TZ ae47pXaJsQhon4qJ8b4CELbgINvqsv82SUKbcB60E8b4w7T49oIKwsWIr1kefg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1692106435; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=+/AQq+p6PLYRselyWhAIq+mJ7duwc6J/7QRyh20GWGg=; b=k7NmyOLQmzq0WxV8RtiNtQenWZ9nXYW1R7xC7UB+UdJ5uTCrgDPNlQrxH4DvnVt8omEIJu 7XCta6as45qdJ0R6rfuLXmIZ34DBTAuYc+3oKa7K5W/EgGOi6UiKyXcTUuqFHxSjjoNuzT nfhv13aoC9IgXjx9uzvjMfigov+2O4VakiCL1f1OC6zlxu23Ie85jnWyyzYTmZVFuSWcPJ hvTV833acvVQlXoHjUukBtf+Uh79kqNZ8NuT4dNBBYn8uwQBRmhkIfpszI0EQ7cV0uexl5 gGP0UoXHMD7Nn+477vqL5HWuyB6qV39NeflNmEZKeKewwDuRnzy4avA5GGgDAA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1692106435; a=rsa-sha256; cv=none; b=FVE3dlqjEwcccutt+hMbLbNhbcOIiQAckL03UOyGbsM0+VmmX+TJvqWF3WsqqVOelMpw1y e2R2+e64f0ba+nzSOWL2zSrLrW9CEKCNRp/15blQFIZDaJK1U4IPmd4mg7bcDizVWGHPKg 775pips8DDv6l/v3HsulMJIYtYlMdz5n+EbBgIJQvVQoxc3mCITtS4pnLBL05OpjdaBx39 C7wzAUhvrjXmxnDBjbJfFyTU82R+PW8PBkdVYzRrlYXtXXwid1OaXoj+8n9FCuHhsNH3vX QdDKWf7Cei7zgiuAHb+WsDTdO3NzHGrrewx/N0nP7iyLEe656Cbhtobs8jfArA== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from [IPV6:2003:cd:5f22:b800:a0bd:ff3:86e9:2d10] (p200300cd5f22b800a0bd0ff386e92d10.dip0.t-ipconnect.de [IPv6:2003:cd:5f22:b800:a0bd:ff3:86e9:2d10]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: se/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4RQC0M2YSKzq4j; Tue, 15 Aug 2023 13:33:55 +0000 (UTC) (envelope-from se@FreeBSD.org) Message-ID: <14dcb339-f578-4eb5-85d2-84197c63a7bb@FreeBSD.org> Date: Tue, 15 Aug 2023 15:33:54 +0200 List-Id: Binary package management and package tools discussion List-Archive: https://lists.freebsd.org/archives/freebsd-pkg List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-pkg@freebsd.org MIME-Version: 1.0 User-Agent: Mozilla Thunderbird From: Stefan Esser Subject: Re: pkg-query(8): unknown query format key: '%i' Content-Language: de-DE, en-US To: Graham Perrin References: <88d40ec4-1b5a-4d5e-b6f7-618a3b31fdbb@gmail.com> <24fbb352-18bc-42b9-f9c8-b7139c6991f3@gmail.com> Cc: freebsd-pkg@freebsd.org In-Reply-To: <24fbb352-18bc-42b9-f9c8-b7139c6991f3@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Am 15.08.23 um 14:06 schrieb Graham Perrin: > > On 15/08/2023 08:30, Graham Perrin wrote: >> %o works, why does %i not work? >> >> >> % pkg query '%o' sddm >> x11/sddm >> % pkg query '%i' sddm >> Unknown query format key: '%i' >> % >> >> >> > > Someone responded off-list. > > I half-get it now, %i is a variable under > . > > Originally, what I wanted was, to get additional information. > > Now, I can't figure out how to use %i as a variable. I had looked at a man-page that documents the currently implemented functionality of the pkg command, and it did not mention '%i'. But looking at the sources of pkg-1.20.5 and 1.20.99.5, '%i' is in fact mentioned in both pkg-query.8 and pkg_printf.3 - but neither of the source files does contain code to support that variable ... Checking the repository, I see that support for %i had been added to the pkg query man page back in 2012: https://github.com/freebsd/pkg/commit/966b5b4c07 But looking at the sources from that time, support for %i did not exist then, but might just have been proposed. See for example the table starting at line 45 in a version from 2014: https://github.com/freebsd/pkg/blob/1.3.0.a2/src/query.c I did not check all versions in the repository, but some between 2012 and the example from 2014 above. Maybe there is some mention of it in the mail list archive ... Regards, STefan