From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id E32BB1382C5 for ; Fri, 15 Jan 2021 18:35:06 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 22E0DE0875; Fri, 15 Jan 2021 18:35:06 +0000 (UTC) Received: from smtp.gentoo.org (dev.gentoo.org [IPv6:2001:470:ea4a:1:5054:ff:fec7:86e4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 0BAAAE0875 for ; Fri, 15 Jan 2021 18:35:06 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 08923335D75 for ; Fri, 15 Jan 2021 18:35:04 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id B59DF53 for ; Fri, 15 Jan 2021 18:35:02 +0000 (UTC) From: "Fabian Groffen" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Fabian Groffen" Message-ID: <1610735487.a9911165da14ccb9a905b5f3e0b076a0f50b852b.grobian@gentoo> Subject: [gentoo-commits] proj/portage:prefix commit in: bin/install-qa-check.d/ X-VCS-Repository: proj/portage X-VCS-Files: bin/install-qa-check.d/05prefix X-VCS-Directories: bin/install-qa-check.d/ X-VCS-Committer: grobian X-VCS-Committer-Name: Fabian Groffen X-VCS-Revision: a9911165da14ccb9a905b5f3e0b076a0f50b852b X-VCS-Branch: prefix Date: Fri, 15 Jan 2021 18:35:02 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 89ae24c0-e477-4b18-99a6-e8e1d69b6b24 X-Archives-Hash: 946f6361615244391818e237a9dff34e commit: a9911165da14ccb9a905b5f3e0b076a0f50b852b Author: Fabian Groffen gentoo org> AuthorDate: Fri Jan 15 18:31:27 2021 +0000 Commit: Fabian Groffen gentoo org> CommitDate: Fri Jan 15 18:31:27 2021 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=a9911165 bin/install-qa-check.d/05prefix: silence grep for shebangs on binaries Two birds one stone: - silence grep on binary files if they happen to contain #! - don't process binary files at all (because we only want text files) While at it, also look for "# !" which is the official form to write the shebang. Signed-off-by: Fabian Groffen gentoo.org> bin/install-qa-check.d/05prefix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bin/install-qa-check.d/05prefix b/bin/install-qa-check.d/05prefix index 03da3bbce..959c85b1b 100644 --- a/bin/install-qa-check.d/05prefix +++ b/bin/install-qa-check.d/05prefix @@ -51,7 +51,7 @@ install_qa_check_prefix() { fi # this is hell expensive, but how else? find "${ED%/}/" -executable \! -type d -print0 \ - | xargs -0 grep -H -n -m1 "^#!" \ + | xargs -0 grep -IHnm1 '^# \?!' \ | while read f ; do local fn=${f%%:*}