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 C24501382C5 for ; Sat, 6 Mar 2021 20:21:58 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 25840E081E; Sat, 6 Mar 2021 20:21:58 +0000 (UTC) Received: from smtp.gentoo.org (smtp.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 0C68AE081E for ; Sat, 6 Mar 2021 20:21:58 +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 D86F833BE65 for ; Sat, 6 Mar 2021 20:21:56 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 5CC7B53 for ; Sat, 6 Mar 2021 20:21:55 +0000 (UTC) From: "Zac Medico" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Zac Medico" Message-ID: <1615062046.4f60b68fca342cc92ed7729d241e2c60132876e8.zmedico@gentoo> Subject: [gentoo-commits] proj/portage:master commit in: lib/portage/util/ X-VCS-Repository: proj/portage X-VCS-Files: lib/portage/util/bin_entry_point.py X-VCS-Directories: lib/portage/util/ X-VCS-Committer: zmedico X-VCS-Committer-Name: Zac Medico X-VCS-Revision: 4f60b68fca342cc92ed7729d241e2c60132876e8 X-VCS-Branch: master Date: Sat, 6 Mar 2021 20:21:55 +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: 9d62b838-5631-48af-8932-736b477e4102 X-Archives-Hash: ba10f239e2dab458f96212602e866f9e commit: 4f60b68fca342cc92ed7729d241e2c60132876e8 Author: Zac Medico gentoo org> AuthorDate: Sat Mar 6 20:20:30 2021 +0000 Commit: Zac Medico gentoo org> CommitDate: Sat Mar 6 20:20:46 2021 +0000 URL: https://gitweb.gentoo.org/proj/portage.git/commit/?id=4f60b68f bin_entry_point: handle versioned python shebangs Signed-off-by: Zac Medico gentoo.org> lib/portage/util/bin_entry_point.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/portage/util/bin_entry_point.py b/lib/portage/util/bin_entry_point.py index ce95231eb..7d359052e 100644 --- a/lib/portage/util/bin_entry_point.py +++ b/lib/portage/util/bin_entry_point.py @@ -20,7 +20,7 @@ def bin_entry_point(): if os.access(script_path, os.X_OK): with open(script_path, "rt") as f: shebang = f.readline() - python_match = re.search(r"/python\s+([^/]*)\s+$", shebang) + python_match = re.search(r"/python[\d\.]*\s+([^/]*)\s+$", shebang) if python_match: sys.argv = [ os.path.join(os.path.dirname(sys.argv[0]), "python"),