From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Philip Kaludercic Newsgroups: gmane.emacs.devel Subject: Re: Automatic Suggestion of Packages Date: Fri, 08 Nov 2024 14:02:20 +0000 Message-ID: <87msi9hlhv.fsf@posteo.net> References: <10864c02-4bfd-41c3-bb45-6fe1155f9676@gutov.dev> <867ca9shcw.fsf@gnu.org> <7cb15f5c-efd0-4516-8190-a53c0d958eb6@gutov.dev> <86ses8x1po.fsf@gnu.org> <865xp3w64u.fsf@gnu.org> <61171da3-7428-4572-bc13-783766a123b5@gutov.dev> <86v7x2u7rz.fsf@gnu.org> <877c9hizof.fsf@web.de> <86cyj9u71k.fsf@gnu.org> <8734k5ipx3.fsf@web.de> <868qtxtx2p.fsf@gnu.org> <87a5ed605a.fsf@posteo.net> <87y11xh4cy.fsf@web.de> <87ikt1ust4.fsf@posteo.net> <87pln8hfh6.fsf@web.de> <87ttcjt9ht.fsf_-_@posteo.net> <87ttcjt4cu.fsf@gmail.com> <87v7wyhfwo.fsf@posteo.net> <87ldxutl71.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="16464"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel@gnu.org To: Visuwesh Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Nov 08 15:03:58 2024 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1t9Pag-00047y-7n for ged-emacs-devel@m.gmane-mx.org; Fri, 08 Nov 2024 15:03:58 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1t9PZK-0004xv-Kq; Fri, 08 Nov 2024 09:02:34 -0500 Original-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 1t9PZH-0004wr-Pg for emacs-devel@gnu.org; Fri, 08 Nov 2024 09:02:31 -0500 Original-Received: from mout01.posteo.de ([185.67.36.65]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1t9PZF-0006in-4h for emacs-devel@gnu.org; Fri, 08 Nov 2024 09:02:31 -0500 Original-Received: from submission (posteo.de [185.67.36.169]) by mout01.posteo.de (Postfix) with ESMTPS id 5D9A8240027 for ; Fri, 8 Nov 2024 15:02:25 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1731074545; bh=aTABmo9b3rMDeaSBCV6/PoPvpQSYYvJxysJbm4hWI8c=; h=From:To:Cc:Subject:Autocrypt:OpenPGP:Date:Message-ID:MIME-Version: Content-Type:Content-Transfer-Encoding:From; b=Re4V++4BUGEJ8rQ/JG67wtWOD8vRue0qce9yIANLlsslkW0yWKuAY+pVPsQmlpo31 l7ybJC7da56Tp3eEAeirOEWj9+cUu1Kz4AAt7bu/d2c7bHHMwSerSmB+KkHP+0oeBt athFGwt0l20Tk3EkSM2ZnDbV5l9I4jCCXaBIFy6eKfYXKPcAd/MH46TsDMg+ZnBwMD 7brRr7lbF4bIM+NwtyFfC/t6t8mAr17Yz4ZKDN3TC2hfGnJNWyyURZL2nVS6E2P/uw ZREzELO7WRWEbxfARR6+PgD45Tr8g7hqsUSt/CctaY1cfC8rA9T2DUpTHE7/dXQ5yX ydPlVKgJENuhA== Original-Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4XlLH418cTz6tvs; Fri, 8 Nov 2024 15:02:22 +0100 (CET) In-Reply-To: <87ldxutl71.fsf@gmail.com> (Visuwesh's message of "Fri, 08 Nov 2024 09:45:46 +0530") Autocrypt: addr=philipk@posteo.net; keydata= mDMEZBBQQhYJKwYBBAHaRw8BAQdAHJuofBrfqFh12uQu0Yi7mrl525F28eTmwUDflFNmdui0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiWBBMWCAA+FiEEDg7HY17ghYlni8XN8xYDWXahwukFAmQQUEICGwMFCQHhM4AFCwkI BwIGFQoJCAsCBBYCAwECHgECF4AACgkQ8xYDWXahwulikAEA77hloUiSrXgFkUVJhlKBpLCHUjA0 mWZ9j9w5d08+jVwBAK6c4iGP7j+/PhbkxaEKa4V3MzIl7zJkcNNjHCXmvFcEuDgEZBBQQhIKKwYB BAGXVQEFAQEHQI5NLiLRjZy3OfSt1dhCmFyn+fN/QKELUYQetiaoe+MMAwEIB4h+BBgWCAAmFiEE Dg7HY17ghYlni8XN8xYDWXahwukFAmQQUEICGwwFCQHhM4AACgkQ8xYDWXahwukm+wEA8cml4JpK NeAu65rg+auKrPOP6TP/4YWRCTIvuYDm0joBALw98AMz7/qMHvSCeU/hw9PL6u6R2EScxtpKnWof z4oM OpenPGP: id=philipk@posteo.net; url="https://keys.openpgp.org/vks/v1/by-email/philipk@posteo.net"; preference=signencrypt Received-SPF: pass client-ip=185.67.36.65; envelope-from=philipk@posteo.net; helo=mout01.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 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, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, RCVD_IN_VALIDITY_CERTIFIED_BLOCKED=0.001, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:325285 Archived-At: Visuwesh writes: > [=E0=AE=B5=E0=AE=BF=E0=AE=AF=E0=AE=BE=E0=AE=B4=E0=AE=A9=E0=AF=8D =E0=AE= =A8=E0=AE=B5=E0=AE=AE=E0=AF=8D=E0=AE=AA=E0=AE=B0=E0=AF=8D 07, 2024] Philip = Kaludercic wrote: > >>> Can we have an user option to both `message' the user and have a button >>> in the mode-line? I usually don't notice changes in the mode-line >>> often, but notice messages in the echo-area. Just having `message' >>> would lose the convenient mode-line button to auto-install the suggested >>> package. >> >> We can do that, it might be worth discussing if the user option should >> be re-designed. The current styles of presenting suggestions are: >> >> 1. A button in the mode-line (default) >> 2. A message with a hint to use `package-autosuggest' (which I think is >> convenient enough) >> 3. A `yes-or-no-p'-prompt to install a package (either every time a >> suggestion is available or only once per package) >> >> I don't know if the last one makes sense to have, as it is pretty >> aggressive. > > Indeed, I agree that it feels very un-Emacsy to be up in the face like > that. > >> Perhaps it makes sense to always present a message if the minor mode >> is enabled, and add a separate option to enable the mode-line button? > > I would be happy with this (though I would turn the mode-line button on > by default). The issue with enable-by-default in the current implementation is that we would have to load package.el by default, which is currently avoided to reduce the startup time (see `package-enable-at-startup'). We could extract the autosuggest logic into a separate file and suggest loading that by default. We could also consider not using the mode line, but the menu bar to hint at package suggestions, but that might be easy to miss especially if a lot of people advise disabling the menu bar. Visuwesh writes: > [=E0=AE=B5=E0=AF=86=E0=AE=B3=E0=AF=8D=E0=AE=B3=E0=AE=BF =E0=AE=A8=E0=AE= =B5=E0=AE=AE=E0=AF=8D=E0=AE=AA=E0=AE=B0=E0=AF=8D 08, 2024] Visuwesh wrote: > >> [=E0=AE=B5=E0=AE=BF=E0=AE=AF=E0=AE=BE=E0=AE=B4=E0=AE=A9=E0=AF=8D =E0=AE= =A8=E0=AE=B5=E0=AE=AE=E0=AF=8D=E0=AE=AA=E0=AE=B0=E0=AF=8D 07, 2024] Philip = Kaludercic wrote: >> >>>> Can we have an user option to both `message' the user and have a button >>>> in the mode-line? I usually don't notice changes in the mode-line >>>> often, but notice messages in the echo-area. Just having `message' >>>> would lose the convenient mode-line button to auto-install the suggest= ed >>>> package. >>> >>> We can do that, it might be worth discussing if the user option should >>> be re-designed. The current styles of presenting suggestions are: >>> >>> 1. A button in the mode-line (default) >>> 2. A message with a hint to use `package-autosuggest' (which I think is >>> convenient enough) >>> 3. A `yes-or-no-p'-prompt to install a package (either every time a >>> suggestion is available or only once per package) >>> >>> I don't know if the last one makes sense to have, as it is pretty >>> aggressive. >> >> Indeed, I agree that it feels very un-Emacsy to be up in the face like >> that. >> >>> Perhaps it makes sense to always present a message if the minor mode >>> is enabled, and add a separate option to enable the mode-line button? >> >> I would be happy with this (though I would turn the mode-line button on >> by default). > > BTW, I looked at the code to see what it does when there's multiple > packages suggested for a single (e.g., racket: racket-mode and > geiser-racket). It seems to install and enable only the first > suggestion: should we instead prompt the user about it? But asking the > user would defeat the purpose of the feature, which helps in assisting > her in setting up her environment for her work. No the current implementation would just install everything. Neither of the two solutions are really ideal. Perhaps we need to pop up a buffer with clickable elements to present the package suggestions and propose installing one of them? --=20 Philip Kaludercic on siskin