From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from pigeon.gentoo.org ([208.92.234.80] helo=lists.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1Nx4iJ-0000c1-Gb for garchives@archives.gentoo.org; Wed, 31 Mar 2010 20:40:35 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id A0D59E067D; Wed, 31 Mar 2010 20:40:29 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 02D50E0B0E for ; Wed, 31 Mar 2010 20:40:25 +0000 (UTC) Received: from [192.168.22.10] (ip68-4-152-120.oc.oc.cox.net [68.4.152.120]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTP id 82A481B402D for ; Wed, 31 Mar 2010 20:40:24 +0000 (UTC) Message-ID: <4BB3B3AC.2020009@gentoo.org> Date: Wed, 31 Mar 2010 13:42:20 -0700 From: Zac Medico User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9.1.8) Gecko/20100315 Thunderbird/3.0.3 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] Unnecessary logs: has_version to the rescue? References: <4BB3ABC8.7050207@gentoo.org> <20100331211904.0f49cae0@snowmobile> <4BB3B11A.1020505@gentoo.org> <4BB3B279.4060308@gentoo.org> In-Reply-To: <4BB3B279.4060308@gentoo.org> X-Enigmail-Version: 1.0.1 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Archives-Salt: 170c8fa8-036d-42f8-b953-14c8f631436b X-Archives-Hash: dd37103b6c5c388cfd751dc2ca02c00f On 03/31/2010 01:37 PM, Sebastian Pipping wrote: > On 03/31/10 22:31, Zac Medico wrote: >> For those who may not know, has_version can be called in pkg_preinst >> to find the previous version, and the result can be stored in a >> variable for us in pkg_postinst. > > So has_version takes the version just installed into account when called > from pkg_postinst? If so wouldn't be banning it's usage from that stage > a good idea? I just checked the code, no such check, yet. Well, it works fine when not called for the same $CATEGORY/$PN, and even for the same $CATEGORY/$PN it works fine for other slots it they happen to be installed. -- Thanks, Zac