From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from omta038.useast.a.cloudfilter.net (omta038.useast.a.cloudfilter.net [44.202.169.37]) by sourceware.org (Postfix) with ESMTPS id A86AA3858C52 for ; Thu, 4 Apr 2024 13:32:29 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org A86AA3858C52 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=tromey.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=tromey.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org A86AA3858C52 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=44.202.169.37 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712237551; cv=none; b=qu2kKCFTbMCCbaV60l1pu/Rb4Hz3ImMwXxOZvqorm+0ZHbkuFLnAPOB/TiLnrdZh/x9VieP1ICB0pRCeFe98bhKT0SmZBvpT8QoPJibPfhtxY6HFWhjhif7wpRUC5kyYCPnxSa6mTVD7tN6++03DXoEpbaUVB3nqKex2CYPKULw= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712237551; c=relaxed/simple; bh=b5fkOzr9h0+rn80QJmHY1RuRv3Dy5Vl9pfFQ13pTYcY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=TWAqCQQ9axf/R7viLEr6nVMF3tY0EYMZS9Q6JQrBtuzgTljdlpmraKksQMeJQ5DPkLaIsk8+pniAdHUjjykRmjbAf5D+GxsOMg8+TyKf0lal2MR+3PHywZx0ayjzBhH+6qYkeH+t0/at/xHwUcrU8VJFxvPo3UjwaeTksytCLh8= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from eig-obgw-6007a.ext.cloudfilter.net ([10.0.30.247]) by cmsmtp with ESMTPS id sFNdrjvvmQr4SsNCfr03nW; Thu, 04 Apr 2024 13:32:29 +0000 Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTPS id sNCdrSS2HVdensNCerypa9; Thu, 04 Apr 2024 13:32:28 +0000 X-Authority-Analysis: v=2.4 cv=M4FLKTws c=1 sm=1 tr=0 ts=660eabec a=ApxJNpeYhEAb1aAlGBBbmA==:117 a=ApxJNpeYhEAb1aAlGBBbmA==:17 a=raytVjVEu-sA:10 a=Qbun_eYptAEA:10 a=A8oJy8mYAAAA:8 a=Komh0OlFcXD8_vbmjvsA:9 a=zgiPjhLxNE0A:10 a=MasS0_dV9q-jaWZIey9J:22 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=tromey.com; s=default; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:References :Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=yBGtkn01ZvKccmjFuJlR1y7qympAgCIPdClWLQD8A5Q=; b=p/ryl9pkUoxlKjMJyJmcT1EmUS Tn+1fcP2gluGu0ZpYOwvzNH8BdVJ6d0zd1dAmJoSAcquVItLQcL5iyz+aR6tTIWIdAqHQQIL6/zts SzbevrjYyBLo2LZFv/EQQ5kjk; Received: from 97-122-82-115.hlrn.qwest.net ([97.122.82.115]:32860 helo=murgatroyd) by box5379.bluehost.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96.2) (envelope-from ) id 1rsNCd-002nWB-1X; Thu, 04 Apr 2024 07:32:27 -0600 From: Tom Tromey To: Tom Tromey Cc: gcc-patches@gcc.gnu.org, libstdc++@gcc.gnu.org Subject: Re: [RFC 0/2] black, isort, and flake8 configuration References: <20231004165832.1750191-1-tromey@adacore.com> X-Attribution: Tom Date: Thu, 04 Apr 2024 07:32:26 -0600 In-Reply-To: <20231004165832.1750191-1-tromey@adacore.com> (Tom Tromey's message of "Wed, 4 Oct 2023 10:58:30 -0600") Message-ID: <87a5m96yol.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - box5379.bluehost.com X-AntiAbuse: Original Domain - gcc.gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - tromey.com X-BWhitelist: no X-Source-IP: 97.122.82.115 X-Source-L: No X-Exim-ID: 1rsNCd-002nWB-1X X-Source: X-Source-Args: X-Source-Dir: X-Source-Sender: 97-122-82-115.hlrn.qwest.net (murgatroyd) [97.122.82.115]:32860 X-Source-Auth: tom+tromey.com X-Email-Count: 3 X-Org: HG=bhshared;ORG=bluehost; X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-CMAE-Envelope: MS4xfLsR/J3xkgCn6F+J9nNg5CaG/yiknD2rN7xskJh0J0DZuhQWPSsgFHFdyjCMyr6ZRJe2INNXamPFVmRw0zzhDMDm3jc0d+7JQYHJkPz5G6+uEsWkMgd4 iVMze1HHgo5Tp+s19NOk5D+qzCGIwQTuEgk/S4IcwSSY9zVANob4u3FkJgIS417/EAffKkBkRDqm+S3QRp/O63FX6qVn4BOP4t0= X-Spam-Status: No, score=-3015.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,JMQ_SPF_NEUTRAL,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: >>>>> "Tom" == Tom Tromey writes: Tom> This short series adds configuration files for black ("opinionated" Tom> code formatter), isort (import sorter) and flake8 (Python lint) to Tom> libstdc++. Tom> I marked it as RFC since sometimes people don't like black's output. Tom> In gdb we use it -- at first I found some of its decisions a little Tom> odd, but overall it's nice not to have to review for or worry about Tom> the minitia of code formatting. FWIW in gdb we recently updated our .pre-commit-config.yaml to automatically run all three of these tools. What this means is that it's now very easy for developers to ensure that the Python code in the tree remains clean -- is correctly formatted, passes flake8 checking, etc. The tool is opt-in but also extremely easy to use. Anyway, if you're at all interested, I could refresh this series to enable flake8 cleanliness and then add a .pre-commit-config.yaml as well. thanks, Tom