From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from omta40.uswest2.a.cloudfilter.net (omta40.uswest2.a.cloudfilter.net [35.89.44.39]) by sourceware.org (Postfix) with ESMTPS id 682173858C56 for ; Thu, 4 Apr 2024 13:32:30 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 682173858C56 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 682173858C56 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=35.89.44.39 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712237553; cv=none; b=kjpjrYgVuifIJyrMd1/ndlM/wd/eRthKkK++XaQrcv0aEcTnGKDiEEyNVXfYewRSSy7OMSrB0Lz5hr00auDjJpoHwjVw1ItU2DfHaje84Ka2xOUjfE8TsOmu4QZU8mCFqWg/LYo+YeQxkpybx5Yt9NmcSTzFLjDvmtW6aOqnxvc= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712237553; c=relaxed/simple; bh=b5fkOzr9h0+rn80QJmHY1RuRv3Dy5Vl9pfFQ13pTYcY=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=WmFmd+tF7P9KtjAxdjZAfLWVPs5zmR1XoMJ0s6aCKyHNwURRCxC3FNXR5bGyZLeRKyUKGcq253EL+AGCbMGOj2aiLEbMJFn8WZhhrKfObXtmY/RKyfPY+1jtGAY3meL75WHqnZuwptbp91K5lBs9OmvnJQxay6VTv3VxCcr7SoM= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from eig-obgw-6004a.ext.cloudfilter.net ([10.0.30.197]) by cmsmtp with ESMTPS id sFNgrN7TDPM1hsNCfrDbJ8; Thu, 04 Apr 2024 13:32:29 +0000 Received: from box5379.bluehost.com ([162.241.216.53]) by cmsmtp with ESMTPS id sNCdrhzkvuv6XsNCer7kj6; Thu, 04 Apr 2024 13:32:28 +0000 X-Authority-Analysis: v=2.4 cv=YbZ25BRf 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: 2 X-Org: HG=bhshared;ORG=bluehost; X-Source-Cap: ZWx5bnJvYmk7ZWx5bnJvYmk7Ym94NTM3OS5ibHVlaG9zdC5jb20= X-Local-Domain: yes X-CMAE-Envelope: MS4xfKGv4kNEOTdJOK8oDYgXGVGFY+oTggD1AUGC+DXz+TwpvH6KzA0rCINIZGjfoRLkO5bFRPM09Fk7X2P1LoSIwbno11QE0fgSWxERH/Bsldhei89bREDT N4Sq39WYefu9/4kKjzKnTSTOUrfBu88Pqh9itw6HnQC5FqGq9YSnGB9GuLoAefIlLfh/HHZ8cWHx1oEeGn6iihCAriMNCLbUlBQ= X-Spam-Status: No, score=-3015.4 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,JMQ_SPF_NEUTRAL,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,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