Missing argument for option: n
Opened this issue · 4 comments
I am getting this error right now:
Missing argument for option: n
Eclipse:
Version: Mars.1 (4.5.1)
Build id: Z20151013-1620
Java:
openjdk version "1.8.0_65"
OpenJDK Runtime Environment (build 1.8.0_65-b17)
OpenJDK 64-Bit Server VM (build 25.65-b01, mixed mode)
the eclimd server prints this at the time of the error:
NGSession 1: 127.0.0.1: org.eclim.command.Main exited with status 1
That said it's my first attempt at setting up eclim, it's very likely I misconfigured something. Using it through the spacemacs integration.
Getting this on find-references but it seems most of the commands trigger that problem.
Seems to be like #180 which was closed.
Can you turn on debug messages and paste what gets added to the *Messages*
buffer?
To turn on debug messages use M-: (setq eclim-print-debug-messages t)
. Then call M-x eclim-java-find-declaration
. After this you should see a line like the following added to the *Messages*
buffer.
Executing: /home/user/bin/eclim -command java_search -n my_project -f src/main/java/org/company/project/MyClass.java -o 1151 -l 3 -x declaration
hmm I ran it several times, I think I got the important error only the first time. It's got to be "invalid project":
Executing: ~/.eclipse/org.eclipse.platform_793567567_linux_gtk_x86_64/eclim -command project_list
eclim--check-project: invalid project:
Executing: ~/.eclipse/org.eclipse.platform_793567567_linux_gtk_x86_64/eclim -command project_by_resource -f /home/emmanuel/projects/bus/generic/core/src/main/java/com/lecip/core/application/LambdaHelpers.java
Executing: ~/.eclipse/org.eclipse.platform_793567567_linux_gtk_x86_64/eclim -command project_by_resource -f /home/emmanuel/projects/bus/generic/core/src/main/java/com/lecip/core/application/LambdaHelpers.java [2 times]
Executing: ~/.eclipse/org.eclipse.platform_793567567_linux_gtk_x86_64/eclim -command project_link_resource -f /home/emmanuel/projects/bus/generic/core/src/main/java/com/lecip/core/application/LambdaHelpers.java
Executing: ~/.eclipse/org.eclipse.platform_793567567_linux_gtk_x86_64/eclim -command java_search -n -f -o 1456 -l 16 -x references
byte-code: Missing argument for option: n
Executing: ~/.eclipse/org.eclipse.platform_793567567_linux_gtk_x86_64/eclim -command project_by_resource -f /home/emmanuel/projects/bus/generic/core/src/main/java/com/lecip/core/application/LambdaHelpers.java
I'm probably guilty of not having RTFM here... I just setup the environment, opened a java file and then expected find-references to work. I think I must set up an eclim project probably.. I'll try to read the documentation. Still, even if that's the reason, I guess the error message could be improved.
yes, setting up things using
mvn eclipse:eclipse -DdownloadSources -DdownloadJavadocs
and
M-x eclim-project-create
makes it work! So maybe a more newbie-friendly error message would be better, but otherwise it's not "really" a bug.
I'm using Gradle on my project. If I'm running eclim and I do gradle cleanEclipse
in a shell at my project root, then after saving a .java
file from my project in Emacs, eclimd throws org.eclipse.core.internal.resources.ResourceException
stating the the .project
file is missing.
Maybe eclim should check that this file is present before issuing commands to eclimd?
Should this be reported as a separate bug?