GNU bug report logs - #62407
30.0.50; The command to run elixir-ls on Windows is `language_server.bat`

Previous Next

Package: emacs;

Reported by: 牟 桐 <mou.tong <at> outlook.com>

Date: Thu, 23 Mar 2023 16:16:01 UTC

Severity: normal

Found in version 30.0.50

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: 牟 桐 <mou.tong <at> outlook.com>
Cc: 62407 <at> debbugs.gnu.org
Subject: bug#62407: 30.0.50; The command to run elixir-ls on Windows is `language_server.bat`
Date: Fri, 24 Mar 2023 09:57:00 +0300
> From: 牟 桐 <mou.tong <at> outlook.com>
> CC: "62407 <at> debbugs.gnu.org" <62407 <at> debbugs.gnu.org>
> Date: Fri, 24 Mar 2023 02:22:44 +0000
> 
> 
> > What is the value of shell-file-name on that Windows
> > system?
> 
> It's `cmdproxy.exe` on Windows, after I changed it to `powershell.exe`
> and `cmd.exe`, the eglot's guess stays the same. I guess that is because
> eglot had hardcoded the result here:
> 
> https://github.com/emacs-mirror/emacs/blob/4566a0c6b825a18e6c065da0543b8b942b7db8df/lisp/progmodes/eglot.el#L224-L225
> 
> ``` emacs-lisp-mode
> ((elixir-mode elixir-ts-mode heex-ts-mode)
>  . ("language_server.sh"))
> ```

Can you see if the patch below solves your problem?

diff --git a/lisp/progmodes/eglot.el b/lisp/progmodes/eglot.el
index 058bcec..42793a1 100644
--- a/lisp/progmodes/eglot.el
+++ b/lisp/progmodes/eglot.el
@@ -222,7 +222,10 @@ eglot-server-programs
                                 (dart-mode . ("dart" "language-server"
                                               "--client-id" "emacs.eglot-dart"))
                                 ((elixir-mode elixir-ts-mode heex-ts-mode)
-                                 . ("language_server.sh"))
+                                 . ,(if (and (fboundp 'w32-shell-dos-semantics)
+                                             (w32-shell-dos-semantics))
+                                        "language_server.bat"
+                                      "language_server.sh"))
                                 (ada-mode . ("ada_language_server"))
                                 (scala-mode . ,(eglot-alternatives
                                                 '("metals" "metals-emacs")))




This bug report was last modified 2 years and 117 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.