From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id AK+YCNhs/2MWcQAAbAwnHQ (envelope-from ) for ; Wed, 01 Mar 2023 16:18:48 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id mM5eCNhs/2NryAAAauVa8A (envelope-from ) for ; Wed, 01 Mar 2023 16:18:48 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D3093D9B1 for ; Wed, 1 Mar 2023 16:18:47 +0100 (CET) Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=OE38Rzqp; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1677683928; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=ahNvihdBJpbBLw813Evmca2m+C/Ua9aaQtHZuom5mdw=; b=qImhbSxVtLfd47AiRka4yfYzhnayh5fgzQlp0W1MgJRKdVetqKrGTfPbnsMF9MHEnMHqUr 7ZT4HmDILQqBLzo1NWTNZ/xELJ0JVru2lqBZCNECqikP8EgZoggEwIw3oVqGcEh6D3Pr+x qZeKm2FT8Q6IMhgWatMgxvScJ8loM2vE/MMmL7s+YKsc3VCO4MEC7H0mOvwYeWoy3ayz48 SWgkHkbhRHmwAh0b+Ttn0Lw9Mtf1+UKtBa+va6VJSZvE1BuBSrTdzyeW7zyK5Ls7PTPdiJ wrSrEbbc0QqxPHfgRqLNwxmunnwpVbQklFi4VMsfI2sLsqzyNktpOF4od4Hd7g== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=OE38Rzqp; spf=pass (aspmx1.migadu.com: domain of "guix-devel-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-devel-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=key1; d=yhetil.org; t=1677683928; a=rsa-sha256; cv=none; b=QRDl9u6yEYzzvCsXen19t5dcax4m+ujt73ctT/iR1E9jSC2qOyMFXxg38slLiK7bcnH+Hw 1EEQRW6PWrpEgVjRZS1K4MdLqj61Q/Q3ucDRfp9bWGTdV5W0axPMJB2B1ZB+hbEDjd/NnM C7+GDfmFuBB9Vnm0Hl4UxuEiFw54o2bwkaWHKpEgRS0Vs52+Vqs9zMh2XyC/9vRS/oniST q/6jefUxsAx5M6ybBxGUzysbu80r5nSMkk0j2QbjP92ZCwXoPLdeQaOwIXaouGV6E0GyF8 Sugqv4rzCHR6JrWCXnH8zrqFJJ7yMBt7CPannaX5jY6CDqAGb61tOZnTFc7VKw== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pXOCi-0002Qm-GD; Wed, 01 Mar 2023 10:17:16 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pXOCg-0002Lq-Na for guix-devel@gnu.org; Wed, 01 Mar 2023 10:17:14 -0500 Received: from mail-qt1-x833.google.com ([2607:f8b0:4864:20::833]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pXOCe-00080r-VB; Wed, 01 Mar 2023 10:17:14 -0500 Received: by mail-qt1-x833.google.com with SMTP id c19so14505258qtn.13; Wed, 01 Mar 2023 07:17:11 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=ahNvihdBJpbBLw813Evmca2m+C/Ua9aaQtHZuom5mdw=; b=OE38Rzqp9Gzt8Qdr5SzOlSfbRYlzehOtA8tMBHWufyEfOQrBK6Mepp+otCeTh66m6U 2GdphizrMySCYIeNSRbDt/YEkBCo8EGj/9prlGuL7jawfJ/y4pz/CSiBtlXkm6FvquOm +pH8n8Wj/KeYf2rfM3pSwMhdg3srqNQRTFuDwxyg9qq378RKCO2vHHTNV7kaK7tGRxrw OPeRVvMaZSS7J+bP5bR7RkX1i1ViawS2VVTNfMLBNL8U0PJfYqjXg3/VB1Ur2vFLvn1B QHIWcPsjmW71Vo/KTKGu/o1vB2hi65BbOi1ikjtwOAGjvVgSPm1E86QNAeznGxk8pLzx migQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:user-agent:message-id :in-reply-to:date:references:subject:cc:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=ahNvihdBJpbBLw813Evmca2m+C/Ua9aaQtHZuom5mdw=; b=GRaW5P1qGRPEFBQRjOjRcqjaf8rtiaw7jkhd7GxoTqlT/th35UcTx8v0/wB35L1oHm MVfWY2TG/n0ZP3QC0fpS4mOXJBCZPeAaMrTr7fj4rkkFwWQanYhOfh6rE9gAlxbqjPDC 2dYaXYkyHKPAGTWMZrQSxQ1+PeGd4zG8j3HRO9yp7wJLRA78VUMfMPF43wKNbY/M6es+ P9oBujgzv4b15dl+i7YR6lojzdQB55bVzmqLn8rQd3l7ZFQXhQFh+0DNkKFv72tYSHhs orjP0ArvJMyM1fs7tTjz/ucEnuRsyEQaD531KfTkg2PodjuGPS+cirYYhIhnzuM3A0sQ 6Mbw== X-Gm-Message-State: AO0yUKXFd7095FudZl1P2YBu46RJb30jnmCq+2hDzD+qaJPXSGtlnbXT 28b/iEds4FLlVQUAmQaPcRmz8pMSVln6pg== X-Google-Smtp-Source: AK7set+YzMpRzFD2PglxPj874Q5nkz6H/bDrbVAS51hjAKpmAknHEaOUjy1ATr4cKK7LhDdDkaNh3w== X-Received: by 2002:ac8:7f46:0:b0:3bf:dfe2:6312 with SMTP id g6-20020ac87f46000000b003bfdfe26312mr10245754qtk.5.1677683830196; Wed, 01 Mar 2023 07:17:10 -0800 (PST) Received: from hurd (dsl-10-130-29.b2b2c.ca. [72.10.130.29]) by smtp.gmail.com with ESMTPSA id t8-20020ac87608000000b003bfc2fc3235sm8339061qtq.67.2023.03.01.07.17.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Mar 2023 07:17:09 -0800 (PST) From: Maxim Cournoyer To: efraim@flashner.co.il Cc: Ludovic =?utf-8?Q?Court=C3=A8s?= , guix-devel Subject: Re: Feedback on indentation rules References: <20230203221409.15886-2-maxim.cournoyer@gmail.com> <20230203221409.15886-5-maxim.cournoyer@gmail.com> <87357alp9n.fsf_-_@gnu.org> <878rgxws6l.fsf@gmail.com> <871qmg5qpj.fsf@gnu.org> <877cw8hvlk.fsf_-_@gmail.com> Date: Wed, 01 Mar 2023 10:17:08 -0500 In-Reply-To: (Efraim Flashner's message of "Mon, 27 Feb 2023 21:14:59 +0200") Message-ID: <87356oijrf.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2607:f8b0:4864:20::833; envelope-from=maxim.cournoyer@gmail.com; helo=mail-qt1-x833.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guix-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: X-Migadu-Spam-Score: -4.91 X-Spam-Score: -4.91 X-Migadu-Scanner: scn0.migadu.com X-Migadu-Queue-Id: D3093D9B1 List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+larch=yhetil.org@gnu.org Sender: guix-devel-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-TUID: NMg+D4owNVyN Hi Efraim, Efraim Flashner writes: > On Thu, Feb 23, 2023 at 05:20:55PM -0500, Maxim Cournoyer wrote: >> -CC bug#61255 >> +CC guix-devel >>=20 >> Hi Ludovic and guix-devel readers, >>=20 >> Ludovic Court=C3=A8s writes: >>=20 >> > Hi, >> > >> > Maxim Cournoyer skribis: >> > >> >> Ludovic Court=C3=A8s writes: >> >> >>=20 >> [...] >>=20 >> >>> I=E2=80=99m not convinced by the indentation rule for =E2=80=98gexp-= >derivation=E2=80=99 added >> >>> in 82daab42811a2e3c7684ebdf12af75ff0fa67b99: there=E2=80=99s no reas= on to treat >> >>> =E2=80=98gexp->derivation=E2=80=99 differently from other procedures. >> >> >> >> The benefit I saw was that writing >> >> >> >> (gexp->derivation the-name >> >> #~(begin >> >> (the >> >> (multi-line >> >> (gexp))))) >> > >> > I understand, but you know, it=E2=80=99s best to avoid unilaterally ch= anging >> > established conventions. :-) >> > >> > If and when there=E2=80=99s consensus about this change, (guix read-pr= int) >> > should be updated. >>=20 >> OK. I'm not against soliciting more opinions; I'm CC'ing guix-devel, >> hoping some opinionated individuals tip in on this 2021 >> 82daab42811a2e3c7684ebdf12af75ff0fa67b99 commit, more specifically, the >> part that change the indentation rules for .dir-locals.el like this: >>=20 >> --8<---------------cut here---------------start------------->8--- >> + (eval . (put 'gexp->derivation 'scheme-indent-function 1)) >> --8<---------------cut here---------------end--------------->8--- >>=20 >> In the same spirit there was also >> b1c25e2ce364741d1c257d3bb3ab773032807a80 (".dir-locals.el: Add >> indentation rule for computed-file.") made more recently (last month). >>=20 >> The idea was to be able to format gexp->derivation like this: >>=20 >> --8<---------------cut here---------------start------------->8--- >> (gexp->derivation "check-deb-pack" >> (with-imported-modules '((guix build utils)) >> #~(begin >> (use-modules (guix build utils) >> (ice-9 match) >> (ice-9 popen) >> (ice-9 rdelim) >> (ice-9 textual-ports) >> (rnrs base)) >> [...] >> --8<---------------cut here---------------end--------------->8--- >>=20 >> Rather than like this: >>=20 >> --8<---------------cut here---------------start------------->8--- >> (gexp->derivation "check-deb-pack" >> (with-imported-modules '((guix build utils)) >> #~(begin >> (use-modules (guix build utils) >> (ice-9 match) >> (ice-9 popen) >> (ice-9 rdelim) >> (ice-9 textual-ports) >> (rnrs base)) >> --8<---------------cut here---------------end--------------->8--- >>=20 >> (or having to use another 'builder' variable, for example). >>=20 >> What do you all think? > > The second one is waaaay to indented. For myself I sometimes end up > wrapping the lines (although I don't love it) so it looks like this: > > (gexp->derivation > "check-deb-pack" > (with-imported-modules '((guix build utils)) > #~(begin > (use-modules (guix build utils) > (ice-9 match) > (ice-9 popen) > (ice-9 rdelim) > (ice-9 textual-ports) > (rnrs base)) Thanks for the feedback. I wonder if some are of the opinion that since gexp->derivation is a plain function rather than a syntax having a special form for its 2nd argument, we should leave the default indentation rules untouched for it? My take on this would be a pragmatic one: readable code trumps indentation rules purity, but I'm interested to gather all the views. --=20 Thanks, Maxim