* eglot.el defcustomʼs @ 2022-10-25 12:21 Robert Pluim 2022-10-25 12:26 ` João Távora 0 siblings, 1 reply; 6+ messages in thread From: Robert Pluim @ 2022-10-25 12:21 UTC (permalink / raw) To: emacs-devel; +Cc: João Távora Hi João, all the defcustomʼs in eglot.el lack a :version tag. Is that intentional? Robert -- ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: eglot.el defcustomʼs 2022-10-25 12:21 eglot.el defcustomʼs Robert Pluim @ 2022-10-25 12:26 ` João Távora 2022-10-25 12:35 ` Robert Pluim 0 siblings, 1 reply; 6+ messages in thread From: João Távora @ 2022-10-25 12:26 UTC (permalink / raw) To: Robert Pluim; +Cc: emacs-devel [-- Attachment #1: Type: text/plain, Size: 628 bytes --] Hi Robert, On Tue, Oct 25, 2022 at 1:21 PM Robert Pluim <rpluim@gmail.com> wrote: > all the defcustomʼs in eglot.el lack a :version tag. Is that > intentional? No really, probably oversight and the fact that Eglot being a GNU ELPA package (presumably easy to upgrade) doesn't usually mean such version tags are so important. That and the fact that Eglot doesn't really have that many defcustoms. So, if you want to add :version tags, go ahead. Note that Eglot does GNU ELPA double-duty as a :core package, so not sure what you should put there, but others are perhaps better informed than me. João [-- Attachment #2: Type: text/html, Size: 1070 bytes --] ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: eglot.el defcustomʼs 2022-10-25 12:26 ` João Távora @ 2022-10-25 12:35 ` Robert Pluim 2022-10-25 13:24 ` Robert Pluim 0 siblings, 1 reply; 6+ messages in thread From: Robert Pluim @ 2022-10-25 12:35 UTC (permalink / raw) To: João Távora; +Cc: emacs-devel, Stefan Monnier >>>>> On Tue, 25 Oct 2022 13:26:01 +0100, João Távora <joaotavora@gmail.com> said: >> all the defcustomʼs in eglot.el lack a :version tag. Is that >> intentional? João> No really, probably oversight and the fact that Eglot being a João> GNU ELPA package (presumably easy to upgrade) doesn't usually mean João> such version tags are so important. Theyʼre not important until we start changing defaults, and then they offer an easy way for people to identify from when they can start shouting at us :-) João> That and the fact that Eglot doesn't really have that many defcustoms. João> So, if you want to add :version tags, go ahead. Note that Eglot João> does GNU ELPA double-duty as a :core package, so not sure what João> you should put there, but others are perhaps better informed than João> me. Iʼm not sure what the interaction is between :version in defcustomʼs and eglot being a :core package, which is why I asked. Maybe Stefan can enlighten us? Robert -- ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: eglot.el defcustomʼs 2022-10-25 12:35 ` Robert Pluim @ 2022-10-25 13:24 ` Robert Pluim 2022-10-25 14:03 ` João Távora 0 siblings, 1 reply; 6+ messages in thread From: Robert Pluim @ 2022-10-25 13:24 UTC (permalink / raw) To: João Távora; +Cc: emacs-devel, Stefan Monnier [-- Attachment #1: Type: text/plain, Size: 376 bytes --] >>>>> On Tue, 25 Oct 2022 14:35:53 +0200, Robert Pluim <rpluim@gmail.com> said: Robert> Iʼm not sure what the interaction is between :version in defcustomʼs Robert> and eglot being a :core package, which is why I asked. Maybe Stefan Robert> can enlighten us? Anyway, whilst Iʼm looking at defcustomʼs anyway, how about the attached? Robert -- [-- Warning: decoded text below may be mangled, UTF-8 assumed --] [-- Attachment #2: 0001-Fix-eglot-defcustom-types.patch --] [-- Type: text/x-diff, Size: 2680 bytes --] From d9c09863b905886085af88f972a02405c730b2b2 Mon Sep 17 00:00:00 2001 From: Robert Pluim <rpluim@gmail.com> Date: Tue, 25 Oct 2022 15:18:51 +0200 Subject: [PATCH] Fix eglot defcustom types To: emacs-devel@gnu.org * lisp/progmodes/eglot.el (eglot-autoreconnect): Allow for 'nil'. (eglot-connect-timeout): Allow for 'nil' and add descriptions. (eglot-sync-connect): Split boolean into 'nil' and 't' and add descriptions. (eglot-confirm-server-initiated-edits): Change 'symbol' type to 'const'. --- lisp/progmodes/eglot.el | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el index 662c233f30..201fafb671 100644 --- a/lisp/progmodes/eglot.el +++ b/lisp/progmodes/eglot.el @@ -323,13 +323,15 @@ eglot-autoreconnect crashes or network failures. A positive integer number says to only autoreconnect if the previous successful connection attempt lasted more than that many seconds." - :type '(choice (boolean :tag "Whether to inhibit autoreconnection") + :type '(choice (const :tag "Reconnect automatically" t) + (const :tag "Never reconnect" nil) (integer :tag "Number of seconds"))) (defcustom eglot-connect-timeout 30 "Number of seconds before timing out LSP connection attempts. If nil, never time out." - :type 'number) + :type '(choice (number :tag "Number of seconds") + (const :tag "Never time out" nil))) (defcustom eglot-sync-connect 3 "Control blocking of LSP connection attempts. @@ -337,8 +339,9 @@ eglot-sync-connect integer number means block for that many seconds, and then wait for the connection in the background. nil has the same meaning as 0, i.e. don't block at all." - :type '(choice (boolean :tag "Whether to inhibit autoreconnection") - (integer :tag "Number of seconds"))) + :type '(choice (const :tag "Block for `eglot-connect-timeout' seconds" t) + (const :tag "Never block" nil) + (integer :tag "Number of seconds to block"))) (defcustom eglot-autoshutdown nil "If non-nil, shut down server after killing last managed buffer." @@ -363,7 +366,7 @@ eglot-events-buffer-size (defcustom eglot-confirm-server-initiated-edits 'confirm "Non-nil if server-initiated edits should be confirmed with user." :type '(choice (const :tag "Don't show confirmation prompt" nil) - (symbol :tag "Show confirmation prompt" 'confirm))) + (const :tag "Show confirmation prompt" confirm))) (defcustom eglot-extend-to-xref nil "If non-nil, activate Eglot in cross-referenced non-project files." -- 2.38.0.118.g4732897cf0 ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: eglot.el defcustomʼs 2022-10-25 13:24 ` Robert Pluim @ 2022-10-25 14:03 ` João Távora 2022-10-25 14:22 ` Robert Pluim 0 siblings, 1 reply; 6+ messages in thread From: João Távora @ 2022-10-25 14:03 UTC (permalink / raw) To: Robert Pluim; +Cc: emacs-devel, Stefan Monnier [-- Attachment #1: Type: text/plain, Size: 533 bytes --] Looks fine to me! João On Tue, Oct 25, 2022 at 2:24 PM Robert Pluim <rpluim@gmail.com> wrote: > >>>>> On Tue, 25 Oct 2022 14:35:53 +0200, Robert Pluim <rpluim@gmail.com> > said: > > Robert> Iʼm not sure what the interaction is between :version in > defcustomʼs > Robert> and eglot being a :core package, which is why I asked. Maybe > Stefan > Robert> can enlighten us? > > Anyway, whilst Iʼm looking at defcustomʼs anyway, how about the > attached? > > Robert > -- > > -- João Távora [-- Attachment #2: Type: text/html, Size: 1012 bytes --] ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: eglot.el defcustomʼs 2022-10-25 14:03 ` João Távora @ 2022-10-25 14:22 ` Robert Pluim 0 siblings, 0 replies; 6+ messages in thread From: Robert Pluim @ 2022-10-25 14:22 UTC (permalink / raw) To: João Távora; +Cc: emacs-devel, Stefan Monnier >>>>> On Tue, 25 Oct 2022 15:03:25 +0100, João Távora <joaotavora@gmail.com> said: João> Looks fine to me! João> João OK, pushed as 8c3b8c3667 Robert -- ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2022-10-25 14:22 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2022-10-25 12:21 eglot.el defcustomʼs Robert Pluim 2022-10-25 12:26 ` João Távora 2022-10-25 12:35 ` Robert Pluim 2022-10-25 13:24 ` Robert Pluim 2022-10-25 14:03 ` João Távora 2022-10-25 14:22 ` Robert Pluim
Code repositories for project(s) associated with this external index https://git.savannah.gnu.org/cgit/emacs.git https://git.savannah.gnu.org/cgit/emacs/org-mode.git This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.