From owner-svn-ports-all@FreeBSD.ORG Fri Sep 12 13:10:17 2014 Return-Path: Delivered-To: svn-ports-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 846473D9 for ; Fri, 12 Sep 2014 13:10:17 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 64AF5DD7 for ; Fri, 12 Sep 2014 13:10:17 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.9/8.14.9) with ESMTP id s8CDAHhF088412 for ; Fri, 12 Sep 2014 13:10:17 GMT (envelope-from bdrewery@freefall.freebsd.org) Received: (from bdrewery@localhost) by freefall.freebsd.org (8.14.9/8.14.9/Submit) id s8CDAH7V088409 for svn-ports-all@freebsd.org; Fri, 12 Sep 2014 13:10:17 GMT (envelope-from bdrewery) Received: (qmail 90725 invoked from network); 12 Sep 2014 08:10:11 -0500 Received: from unknown (HELO blah) (freebsd@shatow.net@10.10.1.90) by sweb.xzibition.com with ESMTPA; 12 Sep 2014 08:10:11 -0500 Message-ID: <5412F0B3.9050804@FreeBSD.org> Date: Fri, 12 Sep 2014 08:10:11 -0500 From: Bryan Drewery Organization: FreeBSD User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.6.0 MIME-Version: 1.0 To: marino@freebsd.org, ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org, Baptiste Daroussin Subject: Re: svn commit: r367994 - head/Keywords References: <201409112311.s8BNBmDl017809@svn.freebsd.org> <54128F1C.8040904@marino.st> In-Reply-To: <54128F1C.8040904@marino.st> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Sep 2014 13:10:17 -0000 On 9/12/14, 1:13 AM, John Marino wrote: > On 9/12/2014 01:11, Bryan Drewery wrote: >> Author: bdrewery >> Date: Thu Sep 11 23:11:48 2014 >> New Revision: 367994 >> URL: http://svnweb.freebsd.org/changeset/ports/367994 >> QAT: https://qat.redports.org/buildarchive/r367994/ >> >> Log: >> @sample: Alert user that there is a stale file to be removed. >> >> Submitted by: amdmi3 >> With hat: portmgr >> >> Modified: >> head/Keywords/sample.ucl >> head/Keywords/sample.yaml >> >> Modified: head/Keywords/sample.ucl >> ============================================================================== >> --- head/Keywords/sample.ucl Thu Sep 11 22:30:43 2014 (r367993) >> +++ head/Keywords/sample.ucl Thu Sep 11 23:11:48 2014 (r367994) >> @@ -33,5 +33,7 @@ pre-deinstall: <> target_file="${sample_file%.sample}" >> if cmp -s "${target_file}" "${sample_file}"; then >> rm -f "${target_file}" >> + else >> + echo "You may need to manually remove ${target_file} if it's no longer needed." >> fi >> EOD >> >> Modified: head/Keywords/sample.yaml >> ============================================================================== >> --- head/Keywords/sample.yaml Thu Sep 11 22:30:43 2014 (r367993) >> +++ head/Keywords/sample.yaml Thu Sep 11 23:11:48 2014 (r367994) >> @@ -32,4 +32,6 @@ pre-deinstall: | >> target_file="${sample_file%.sample}" >> if cmp -s "${target_file}" "${sample_file}"; then >> rm -f "${target_file}" >> + else >> + echo "You may need to manually remove ${target_file} if it's no longer needed." >> fi >> > > > Is this message going to show when packages are upgraded too? If an > upgrade is a deinstall of old version followed by installation of new > version, I would think it would. > > I'm just wondering if this message is going to be unnecessary more often > than not.... > > John > Yes. It's the same as the user removal message too. It would be good to have pkg tell the deinstall script it is really an upgrade so these sort of messages can be skipped. It could be as simple as pkg exporting an env var PKG_IS_UPGRADING or something to check for. Bapt what do you think of that? Having pkg only call pre/post-upgrade scripts instead of deinstall/install is a much larger task to ensure working properly for all packages I think. -- Regards, Bryan Drewery