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 1QFrJu-0004Rw-3z for garchives@archives.gentoo.org; Fri, 29 Apr 2011 17:17:34 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 96C801C026; Fri, 29 Apr 2011 17:17:23 +0000 (UTC) Received: from mail-wy0-f181.google.com (mail-wy0-f181.google.com [74.125.82.181]) by pigeon.gentoo.org (Postfix) with ESMTP id CBD511C008 for ; Fri, 29 Apr 2011 17:16:48 +0000 (UTC) Received: by wyi11 with SMTP id 11so4009565wyi.40 for ; Fri, 29 Apr 2011 10:16:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:sender:date:from:to:subject:message-id :references:mime-version:content-type:content-disposition :in-reply-to:user-agent; bh=UhzkG7qPqjE0VpYvgB4SqUBd92zE+LtIsvLW2sAifGc=; b=P28Eit26wFNz2scMSIRPcvPDusxxKNuIl6Xf27KBWbkdJ7usc/cAjPD9A/ArcXN2eI uzbCBYwIuU3daQJp94OwdJOouqMgeFhmbyi6kmtrc3zdFII64FB8v9DnxwccZEN89rZf 1BR+ZF84DRISojhgYJlEFvoyrIWUmtHyVdbRA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:date:from:to:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; b=MwaZcxyUQ6AawMecbTkxSIOP5idAD/0mdKP2DpvX9igY3MZp5X/ILtTMJM3hhahnfp gGvBj4JjZmuikfe9mulVFwduPJ2kp/l7i9Z++Ld41a4EwpGWy4V+XfuYDu76t+gii8q4 IpQ0hR6UX1LigNR8/nfvFevQsTmcGJ8C1BOhQ= Received: by 10.227.7.87 with SMTP id c23mr1159238wbc.108.1304097407752; Fri, 29 Apr 2011 10:16:47 -0700 (PDT) Received: from lust (ppp079166174138.dsl.hol.gr [79.166.174.138]) by mx.google.com with ESMTPS id o23sm1823675wbc.44.2011.04.29.10.16.44 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 29 Apr 2011 10:16:46 -0700 (PDT) Sender: Alex Alexander Date: Fri, 29 Apr 2011 20:18:25 +0300 From: Alex Alexander To: gentoo-dev@lists.gentoo.org Subject: Re: [gentoo-dev] openrc portage news item Message-ID: <20110429171825.GA5451@lust> References: <20110413181538.GA2894@linux1> <20110429070831.GA27531@linux1> <20110429122803.0ecc8060@googlemail.com> 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 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="KFztAG8eRSV9hGtP" Content-Disposition: inline In-Reply-To: <20110429122803.0ecc8060@googlemail.com> User-Agent: Mutt/1.5.21 (2010-09-15) X-Archives-Salt: X-Archives-Hash: 49192166e31b6e452c698b93b2d1686c --KFztAG8eRSV9hGtP Content-Type: multipart/mixed; boundary="UlVJffcvxoiEqYs2" Content-Disposition: inline --UlVJffcvxoiEqYs2 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Apr 29, 2011 at 12:28:03PM +0100, Ciaran McCreesh wrote: > On Fri, 29 Apr 2011 07:21:23 -0400 > Rich Freeman wrote: > > Perhaps a future/in-progress EAPI could define a mechanism where an > > ebuild can indicate that a particular update or set of circumstances > > is a system-critical change, and that the package manager should > > consequently alert the user and ensure that they have confirmed the > > action. >=20 > pkg_pretend can do that... indeed. it works quite well too. please have a look at the attached patch. it forces the user to acknowledge and verify that he has read the printed message by prepending a variable to the emerge command. I know it is a bit nasty, but it accomplishes our goal by making sure the users read the message. --=20 Alex Alexander | wired + Gentoo Linux Developer ++ www.linuxized.com --UlVJffcvxoiEqYs2 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="openrc-0.8.2-r1.ebuild.require.verification.patch" Content-Transfer-Encoding: quoted-printable Index: openrc-0.8.2-r1.ebuild =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D RCS file: /var/cvsroot/gentoo-x86/sys-apps/openrc/openrc-0.8.2-r1.ebuild,v retrieving revision 1.1 diff -u -B -r1.1 openrc-0.8.2-r1.ebuild --- openrc-0.8.2-r1.ebuild 28 Apr 2011 19:50:51 -0000 1.1 +++ openrc-0.8.2-r1.ebuild 29 Apr 2011 17:10:34 -0000 @@ -2,7 +2,7 @@ # Distributed under the terms of the GNU General Public License v2 # $Header: /var/cvsroot/gentoo-x86/sys-apps/openrc/openrc-0.8.2-r1.ebuild,= v 1.1 2011/04/28 19:50:51 williamh Exp $ =20 -EAPI=3D"1" +EAPI=3D"4" =20 inherit eutils flag-o-matic multilib toolchain-funcs =20 @@ -34,6 +34,22 @@ DEPEND=3D"${RDEPEND} virtual/os-headers" =20 +pkg_pretend() { + if [[ -z ${REPLACING_VERSIONS} ]] && [[ ${WARNING_OPENRC} !=3D 1 ]]; then + eerror + eerror "You're upgrading your system to openrc. After emerge is" + eerror "complete, you MUST follow the guide located here:" + ewarn " http://www.gentoo.org/doc/en/openrc-migration.xml" + eerror "FAILING TO DO SO WILL PROBABLY RESULT IN AN *NON-BOOTABLE* SYSTE= M." + eerror + eerror "To verify you read and understood this message, please prepend" + ewarn " WARNING_OPENRC=3D1" + eerror "to your emerge command." + eerror + die "We need user verification to proceed." + fi +} + make_args() { unset LIBDIR #266688 =20 --UlVJffcvxoiEqYs2-- --KFztAG8eRSV9hGtP Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (GNU/Linux) iQIcBAEBCAAGBQJNuvLgAAoJEDZF8K7rm0r6+agP/Au3+zkYyxWbXy56a2FpMWQx ksxle3g29I+7u3cyPn0PRd6srpizseXdCE1Ox1Vy743uQrCVQouuRH7IMrqVSxhW ZHN1Qhw2YhKvLgniW9lN/t2aTI/J7nWQ7N2mp8Edjn4J8Fy8XLdryXRp8VXB/i9V YWhvAq+prXpjpGPbHUjgvCzNowVdpK0pG8DwdtQnK7jAaNnr7eZ55BUlF9IIv7JY ZDsqcYciAmCWLYQ12ADTFb6guqgUkQDUfWu7u2LiJNlcHrTuTC78UZBefWZYMAN1 RKjL8V4cciMGbcH9CjgnNPrGNOwKUxN3ds+Ol++9dSypsBuYSt7hC6h7w96CMg/B jJBPSy1zqPQobhOBgAPkUuTvyj3U3JqO1UkOGjVOJSR6VtJLmhsiQ78rzAnf928v vlBQJKu4Jhrq7W5zCyWCGsR/lS3wkZixps+3X9wZzKxESCzTp0iS7iwuc7V0rStY Vap//bmjsDexErZ9dtjcwsZkC3DCp7xa0ap9LXoA5IcPxSlUkdJtXyqCDDtj2but njeSXVjg2MUQokHWNu8XjAIiNyuRKryC+SR7QMgDpSeJK3Kln3KFEuTBkGP2kDX2 Qb4te7YHfsVlR27+Ro8pUHF5+ORx2G6u780GLykrCS6/YiO17dfMqUoywdqHI4vc yP8/xpusRJvKswzrID7f =Uq1k -----END PGP SIGNATURE----- --KFztAG8eRSV9hGtP--