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 <gentoo-dev+bounces-42413-garchives=archives.gentoo.org@lists.gentoo.org>) id 1OneUn-0001Hu-Ss for garchives@archives.gentoo.org; Mon, 23 Aug 2010 21:23:58 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 70A38E08D5; Mon, 23 Aug 2010 21:23:52 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id 620B5E0852 for <gentoo-dev@lists.gentoo.org>; Mon, 23 Aug 2010 21:23:32 +0000 (UTC) Received: from mail.isohunt.com (b01.ext.isohunt.com [208.71.112.51]) by smtp.gentoo.org (Postfix) with ESMTP id 8EA1B1B416F for <gentoo-dev@lists.gentoo.org>; Mon, 23 Aug 2010 21:23:31 +0000 (UTC) Received: (qmail 31338 invoked from network); 23 Aug 2010 21:23:29 -0000 Received: from tsi-static.orbis-terrarum.net (HELO grubbs.orbis-terrarum.net) (76.10.188.108) by mail.isohunt.com (qpsmtpd/0.33-dev on beta01) with (CAMELLIA256-SHA encrypted) ESMTPS; Mon, 23 Aug 2010 21:23:29 +0000 Received: (qmail 26361 invoked by uid 10000); 23 Aug 2010 21:23:27 -0000 Date: Mon, 23 Aug 2010 21:23:27 +0000 From: "Robin H. Johnson" <robbat2@gentoo.org> To: gentoo-dev@lists.gentoo.org Subject: [gentoo-dev] [RFC ECLASS PATCH] Include exact Hg revision data for repeatability from logs. Message-ID: <robbat2-20100823T212204-147972867Z@orbis-terrarum.net> Precedence: bulk List-Post: <mailto:gentoo-dev@lists.gentoo.org> List-Help: <mailto:gentoo-dev+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-dev+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-dev+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-dev.gentoo.org> X-BeenThere: gentoo-dev@lists.gentoo.org Reply-to: gentoo-dev@lists.gentoo.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="iFRdW5/EC4oqxDHL" Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) X-Archives-Salt: 78a6c6a1-d521-4a0d-92b3-e5d3d938cced X-Archives-Hash: fd27e5f58abca8d000f910797160b854 --iFRdW5/EC4oqxDHL Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable The existing EHG_REVISION is the target revision, usually 'tip', so it doesn't help us reproduce a bug if the upstream tree has moved since log creation. Example output: * Work directory: /var/tmp/portage/.... global id: 44cff02c8042 branch: def= ault Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> Index: mercurial.eclass =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/eclass/mercurial.eclass,v retrieving revision 1.12 diff -p -w -b -B -u -r1.12 mercurial.eclass --- mercurial.eclass 2 Apr 2010 18:29:39 -0000 1.12 +++ mercurial.eclass 23 Aug 2010 21:20:41 -0000 @@ -116,12 +116,20 @@ function mercurial_fetch { fi =20 # Checkout working copy: - einfo "Creating working directory in ${WORKDIR}/${module} (revision: ${EH= G_REVISION})" + einfo "Creating working directory in ${WORKDIR}/${module} (target revisio= n: ${EHG_REVISION})" hg clone \ ${EHG_QUIET_CMD_OPT} \ --rev=3D"${EHG_REVISION}" \ "${EHG_STORE_DIR}/${EHG_PROJECT}/${module}" \ "${WORKDIR}/${module}" || die "hg clone failed" + # An exact revision helps a lot for testing purposes, so have some output= =2E.. + # id num branch + # fd6e32d61721 6276 default + local HG_REVDATA=3D($(hg identify -n -b -i "${WORKDIR}/${module}")) + local HG_REV_ID=3D${HG_REVDATA[0]} + local HG_REV_NUM=3D${HG_REVDATA[1]} + local HG_REV_BRANCH=3D${HG_REVDATA[2]} + einfo "Work directory: ${WORKDIR}/${module} global id: ${HG_REV_ID} branc= h: ${HG_REV_BRANCH}" } =20 # @FUNCTION: mercurial_src_unpack --=20 Robin Hugh Johnson Gentoo Linux: Developer, Trustee & Infrastructure Lead E-Mail : robbat2@gentoo.org GnuPG FP : 11AC BA4F 4778 E3F6 E4ED F38E B27B 944E 3488 4E85 --iFRdW5/EC4oqxDHL Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.16 (GNU/Linux) Comment: Robbat2 @ Orbis-Terrarum Networks - The text below is a digital signature. If it doesn't make any sense to you, ignore it. iEYEARECAAYFAkxy5s8ACgkQPpIsIjIzwizx3wCfWvPpfPr/h+XTelrSKTmFw1pR 6qUAnjpaTtxN+QMuoi2PislL+/J7tG45 =iAvi -----END PGP SIGNATURE----- --iFRdW5/EC4oqxDHL--