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 1S8zcY-0002kp-SS for garchives@archives.gentoo.org; Sat, 17 Mar 2012 19:48:59 +0000 Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id DE4A3E0837; Sat, 17 Mar 2012 19:48:50 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) by pigeon.gentoo.org (Postfix) with ESMTP id AAD35E0837 for ; Sat, 17 Mar 2012 19:48:50 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id DD93D1B4025 for ; Sat, 17 Mar 2012 19:48:49 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id A2D27E5402 for ; Sat, 17 Mar 2012 19:48:48 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1332013710.237427dbf5eadf1e7b7bf2962b2ccbb352e527ab.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: bin/ X-VCS-Repository: proj/portage X-VCS-Files: bin/repoman X-VCS-Directories: bin/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 237427dbf5eadf1e7b7bf2962b2ccbb352e527ab X-VCS-Branch: master Date: Sat, 17 Mar 2012 19:48:48 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: quoted-printable X-Archives-Salt: d8e57c2d-b27f-4c04-8230-e2a6e8d8f40d X-Archives-Hash: d978163789025e305337a11a8ca0533c commit: 237427dbf5eadf1e7b7bf2962b2ccbb352e527ab Author: Zac Medico gentoo org> AuthorDate: Sat Mar 17 19:48:30 2012 +0000 Commit: Zac Medico gentoo org> CommitDate: Sat Mar 17 19:48:30 2012 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=3Dproj/portage.git;a= =3Dcommit;h=3D237427db repoman: ignore temp files, bug #406877 If the file isn't in the VCS new or changed set, then assume that it's an irrelevant temporary file. This relies on commit 2dac56fa282645031eb29860abc403e983a04b2d to guarantee that Manifest entries are not generated for file names containing prohibited characters. --- bin/repoman | 22 ++++++++++++++++++++++ 1 files changed, 22 insertions(+), 0 deletions(-) diff --git a/bin/repoman b/bin/repoman index ffedf2e..80fcde2 100755 --- a/bin/repoman +++ b/bin/repoman @@ -1170,6 +1170,12 @@ if vcs: modified_changelogs.update(x for x in chain(mychanged, mynew) \ if os.path.basename(x) =3D=3D "ChangeLog") =20 +def vcs_new_changed(relative_path): + for x in chain(mychanged, mynew): + if x =3D=3D relative_path: + return True + return False + have_pmasked =3D False have_dev_keywords =3D False dofail =3D 0 @@ -1361,6 +1367,14 @@ for x in effective_scanlist: for y in checkdirlist: m =3D disallowed_filename_chars_re.search(y.strip(os.sep)) if m is not None: + y_relative =3D os.path.join(checkdir_relative, y) + if vcs is not None and not vcs_new_changed(y_relative): + # If the file isn't in the VCS new or changed set, then + # assume that it's an irrelevant temporary file (Manifest + # entries are not generated for file names containing + # prohibited characters). See bug #406877. + m =3D None + if m is not None: stats["file.name"] +=3D 1 fails["file.name"].append("%s/%s: char '%s'" % \ (checkdir, y, m.group(0))) @@ -1529,6 +1543,14 @@ for x in effective_scanlist: m =3D disallowed_filename_chars_re.search( os.path.basename(y.rstrip(os.sep))) if m is not None: + y_relative =3D os.path.join(checkdir_relative, "files", y) + if vcs is not None and not vcs_new_changed(y_relative): + # If the file isn't in the VCS new or changed set, then + # assume that it's an irrelevant temporary file (Manifest + # entries are not generated for file names containing + # prohibited characters). See bug #406877. + m =3D None + if m is not None: stats["file.name"] +=3D 1 fails["file.name"].append("%s/files/%s: char '%s'" % \ (checkdir, y, m.group(0)))