From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms9.migadu.com with LMTPS id QCoHAphR7mS4VQAAauVa8A:P1 (envelope-from ) for ; Tue, 29 Aug 2023 22:14:16 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:478a::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id QCoHAphR7mS4VQAAauVa8A (envelope-from ) for ; Tue, 29 Aug 2023 22:14:16 +0200 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 A12B99C18 for ; Tue, 29 Aug 2023 22:14:15 +0200 (CEST) Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20221208 header.b=RFX7bXTm; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1693340056; 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:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=n2nkbAZZFNGQop5NO+RshOg8hw159NE8SZSvch/W/C4=; b=ZE8hOgn6DePdh1eFwvdsjbPjIAR3eGJbSuHziJvrNJ+04Nt9PZvWUFnbEcuCoTPCkfi3NC Kcg/wceYeVqASuiCwJiMA8IEbYKlCaJRYZSA7k7+Q3iXUof1w+2nfSqIERnWtPXcCKJf8Z v/SjzVQthBzuvRXkl5Y3cfo1WhgA0tXaeZTwzLhr938MhR2K2oSLrToniIXE7x9nmRdVMZ Rz5OnMg9mtxMXCrMbkHZC07abrW2Da1AdEaPRatB1lPWC6SMUuI15ZpN7fgWhb4T42t9zM Grt29u3CgamseXsYOwsi2Uc9zOV2AgJ4p5qi3IXUjUo1TPTfoRSDsLrWMZkYTA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20221208 header.b=RFX7bXTm; spf=pass (aspmx1.migadu.com: domain of "bug-guix-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="bug-guix-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Seal: i=1; s=key1; d=yhetil.org; t=1693340056; a=rsa-sha256; cv=none; b=TpSSCiAZPXh1pt3y9Wui1psWfmCt1brwsXOWqF8u3bDGjwAJHrbqTK4tMhCvFNfSdu3jbQ ByrzhxM5zhz05RSioQbW+JYF+BviUkF18T33NZmBaxb6UYmtK6Pw/d1tfzW5yo3DMdofN2 3Ot7HNKahVGmEi80mYT6HkC3CYW66DL7MeBO5akschkbmGfEKxTtR5B22NvZVFrtq+JtVY evdanl5yRoPSmI/LDed9fHbmWZzjmi7B+BaCoC/LyRXQ13BX1x3s8KVqlv3/9wP7Dsnl1m vkEiEDqEx6S536olSEa6FkMj9qEqp3beRo+8jejBWv5x/w5LpflzycvH7DwXdQ== Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qb55r-0004dR-OQ; Tue, 29 Aug 2023 16:13:43 -0400 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 1qb51E-00043Z-9O for bug-guix@gnu.org; Tue, 29 Aug 2023 16:08:57 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qb51D-0000kO-Eh for bug-guix@gnu.org; Tue, 29 Aug 2023 16:08:55 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qb51K-00041H-HU for bug-guix@gnu.org; Tue, 29 Aug 2023 16:09:02 -0400 X-Loop: help-debbugs@gnu.org Subject: bug#65575: [PATCH 3/3] gnu: emacs: Reload subdirs.el files in 'guix-emacs-autoload-packages'. Resent-From: Liliana Marie Prikler Original-Sender: "Debbugs-submit" Resent-CC: bug-guix@gnu.org Resent-Date: Tue, 29 Aug 2023 20:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65575 X-GNU-PR-Package: guix X-GNU-PR-Keywords: To: Maxim Cournoyer Cc: 65575@debbugs.gnu.org Received: via spool by 65575-submit@debbugs.gnu.org id=B65575.169333968615384 (code B ref 65575); Tue, 29 Aug 2023 20:09:02 +0000 Received: (at 65575) by debbugs.gnu.org; 29 Aug 2023 20:08:06 +0000 Received: from localhost ([127.0.0.1]:51627 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qb50P-000403-IH for submit@debbugs.gnu.org; Tue, 29 Aug 2023 16:08:05 -0400 Received: from mail-ej1-x642.google.com ([2a00:1450:4864:20::642]:59426) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qb50M-0003zX-OL for 65575@debbugs.gnu.org; Tue, 29 Aug 2023 16:08:03 -0400 Received: by mail-ej1-x642.google.com with SMTP id a640c23a62f3a-99c4923195dso602427166b.2 for <65575@debbugs.gnu.org>; Tue, 29 Aug 2023 13:07:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1693339670; x=1693944470; darn=debbugs.gnu.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=n2nkbAZZFNGQop5NO+RshOg8hw159NE8SZSvch/W/C4=; b=RFX7bXTmQwcyHMcGkBHb1VEFo9lXdQfkuyQXH0PIoxplAhBFL09JzrPYV4v81yovOp QMitX8UgWPem73Gqu1nTTNC7UTrBco/b7Pw3K+YTbNjGRGxSqgeE+oQk2Dun5p5jeUbX AGlzmvNq8BuDAdQG/cnEr9TCDPvbJZEoGJCrRQq7D1uT+SFS19EbL8Tgep1SDzEcArI9 FF4Edz9Lr26eambNTJBpJMS1SQkycOA4m8Rts/RFKkNqVHgFzouJN/V2C76Il+RvWdj/ wX+JCPnOIV6uesVWKky/dERcRdELA8dU+nqX1qr+OYdpa0Y0o2pRQ5K5/S2yiGvCGp7f QJsg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693339670; x=1693944470; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=n2nkbAZZFNGQop5NO+RshOg8hw159NE8SZSvch/W/C4=; b=EhvAFlCCF2UOQ/ZHVqRUtKBnDapDTj9MTACKl0ghMI1NhSDiQdNzhAnvjQL9fLNTpv XNWJ4fsz1HggYcQIx17Enj/oYJLZnO0W6oQwJukVv9eCMiZaeckX8gF/LK11sOW/CeU6 vfzTbfBtuFXdux6EknzdDuof5r4lopfyEyUQOEQu1qn6VLy0fXwcpwmZEh89hOf0Ist7 JjaVEl8qQvUVqbagASUmFYx9WbSQq8vK8AMxLOvbItI6L+40/kGMPXEVovfZjW4upybj BaKNIEcfal6k6f2u9NmxZWhtc0Rng5cD5PVzPkPCA1lPcBeEq5ssoxwTW5QI2gL0ANPf FZAQ== X-Gm-Message-State: AOJu0YxHkmUDP9NuD8ORWW9OxPoeapKKonUYIMmgGkeyftxq4DUqXLSA c/YypXvkgF+mNIeRloodAyM= X-Google-Smtp-Source: AGHT+IF08aAce5EIALbEYG8VxJjCwjKhHv9oA4h5uZg82VRxq+vnO7s/o1t9iFHOkIJEXL81SsCQ8w== X-Received: by 2002:a17:907:2beb:b0:9a1:e613:2569 with SMTP id gv43-20020a1709072beb00b009a1e6132569mr61736ejc.16.1693339669506; Tue, 29 Aug 2023 13:07:49 -0700 (PDT) Received: from lumine.fritz.box (85-127-52-93.dsl.dynamic.surfer.at. [85.127.52.93]) by smtp.gmail.com with ESMTPSA id p23-20020a170906839700b0099d9b50d786sm6351890ejx.199.2023.08.29.13.07.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 29 Aug 2023 13:07:48 -0700 (PDT) Message-ID: <81e6491a09388339ff1a41f1d1eb72a286f3290c.camel@gmail.com> From: Liliana Marie Prikler Date: Tue, 29 Aug 2023 22:07:46 +0200 In-Reply-To: <87il8zgpm7.fsf@gmail.com> References: <6715bc07d825d632140c63bd98c959d31cc5de47.1693199493.git.maxim.cournoyer@gmail.com> <84a6b9e11ec0f8fcdd865dae40ab41100a5c763c.1693199493.git.maxim.cournoyer@gmail.com> <88f150c1356008a1d1c4251a8ec98afcd6e1b6f2.camel@ist.tugraz.at> <87il8zgpm7.fsf@gmail.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.46.4 MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-guix@gnu.org List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+larch=yhetil.org@gnu.org Sender: bug-guix-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: 2.77 X-Spam-Score: 2.77 X-Migadu-Scanner: mx0.migadu.com X-Migadu-Queue-Id: A12B99C18 X-TUID: LFA2W5CRe6Wt Am Montag, dem 28.08.2023 um 11:20 -0400 schrieb Maxim Cournoyer: > > e.g.=C2=A0 > > (defun guix-emacs-autoload-packages (&optional reload) > > =C2=A0=C2=A0"..." > > =C2=A0 (interactive "P") > > =C2=A0 (when reload (mapc #'load-file (guix-emacs--subdirs-files))) > > =C2=A0 ...) > >=20 > > WDYT? >=20 > The reason for avoiding loading the subdirs.el files on the first > call is just an optimization, since it would at this time duplicate > work already done by Emacs itself when it first executes.=C2=A0 This > shouldn't fail; I've now employed the same 'noerror strategy as used > for autoloads to ensure that. >=20 > There's one edge case I've just thought though, which is if a user > invoked emacs with the documented '--no-site-file' option disabling > loading autoloads; this would cause guix-emacs-autoload-packages- > called to be nil. >=20 > To balance between making things both convenient and flexible, I've > preserved the tracking but also added the reload override you > suggested. Let me know what you think. Assuming convenience equates to not needing to type C-u, we can also achieve that without tracking: (defun guix-emacs-autoload-packages (&optional noexpand) "Autoload Emacs packages found in EMACSLOADPATH. 'Autoload' means to load the 'autoloads' files matching=C2=A0 `guix-emacs-autoloads-regexp'. Before doing so, expand load-path by loading subdirs.el files found in it, unless NOEXPAND is given." (interactive "P") (unless noexpand (mapc #'load-file (guix-emacs--subdirs-files))) ...) In our own init code, we should simply call it as=C2=A0 (guix-emacs-autoload-packages 'noexpand) then, since this expansion is already done earlier by Emacs. Cheers