Open andreaskundig opened 2 years ago
I came here to report my own problem, but it might be the same as this one @andreaskundig reported back in August.
Here is mine:
-*- mode: compilation; default-directory: "c:/Users/FIRST~1.LAS/AppData/Local/Temp/2/lsp-java-installnOskvq/" -*-
Comint started at Fri Feb 3 16:54:31
mvnw.cmd -Djdt.js.server.root\=c\:/bin/msys64/home/firstname.lastname/.emacs.d/.cache/lsp/eclipse.jdt.ls/ -Djunit.runner.root\=c\:/bin/msys64/home/firstname.lastname/.emacs.d/eclipse.jdt.ls/test-runner/ -Djunit.runner.fileName\=junit-platform-console-standalone.jar -Djava.debug.root\=c\:/bin/msys64/home/firstname.lastname/.emacs.d/.cache/lsp/eclipse.jdt.ls/bundles clean package -Djdt.download.url\=https\://download.eclipse.org/jdtls/milestones/1.12.0/jdt-language-server-1.12.0-202206011637.tar.gz
/usr/bin/bash: line 1: mvnw.cmd: command not found
Comint exited abnormally with code 127 at Fri Feb 3 16:54:31
I'm not using git-bash (aka git from git-scm.org, which comes with bash) but I am using msys2 (from msys2.org, which also comes with bash).
And I'm not using doom-emacs, I'm using mingw64/mingw-w64-x86_64-emacs 28.2-2
which is a package that is available within the msys2 environment.
Anyway, I think the problem is that the jdtls installation routines are getting a little confused about whether these systems are unix, or if they are Microsoft Windows. Part of the installation routines (or something) choose to invoke GNU Bash, but some other part chooses to pass the argument mvnw.cmd
to that bash process...
I know a shell script is also available (./mvnw
)... so whenever a shell interpreter is used, that script should be used, too. The mvnw.cmd
file should only be used if cmd.exe
was invoked. (I guess.)
I forgot to mention.. the emacs package in msys2 is quite confused itself.
I see both these strings on my screen right now.. Different parts of the thing are seeing different home directories for my user:
c:/Users/firstname.lastname/
c:/bin/msys64/home/firstname.lastname/
I installed lsp java in doom emacs (latest version) on windows 10. The first time I open a java file, emacs proposes to install jdtls. I accept, but I get the following error:
The same command fails when I run it by hand in git bash
However it works when I add the path in front of the executable