I want to be able to a) tell the remote eclipse to build the project,
and b) load the errors into the local vim's quicklist.
I've got eclim installed on both hosts, and I am able to start the
remote eclimd via eclipse, and it is binding successfully to all
interfaces.
Is there a way to get my local vim/eclim to talk to a remote host? It
doesn't look like :PingEclim has an option to specify a host name...
The best I've been able to do so far is use ssh to create a
tunnel from localhost:9091 to windowshost:9091.
That makes :PingEclim work fine:
:PingEclim
eclim 1.7.2
eclipse 3.7.1^M
...but :ProjectProblems shows:
:ProjectProblems
Unable to determine the project. Please specify a project name or
execute from a valid project directory.
...and :ProjectCreate, run from anywhere in my eclipse workspace,
says:
:ProjectCreate . -n java
Unable to determine your eclipse workspace.
Am I going about this the wrong way? Is this even a supported config?
Thanks,
Steve
This setup is not currently supported.
The first problem you are running into is that the eclimd daemon, when
starting, registers the workspace location and port number to the file
~/.eclim/.eclimd_instances which the vim side then reads to determine
what eclipse workspaces are available, their location, and how to
contact the eclim daemon for each workspace. Since this file is being
created on the Windows machine in your case, the vim instances on your
Linux host cannot see that file and so doesn't know about any
workspaces. You could work around this by creating a
~/.eclim/.eclimd_instances file on your Linux box but then you'll just
start running into the next hurdle.
The second problem you'll encounter is that both vim and eclipse need
local access to the files, but more than that, they both have to be
able to locate the files at the exact same path. Neither side
explicitly knows about the NFS mount so neither side knows how to
locate the file at the path received from the other side. So assuming
your projects are all under the workspace directory, the Windows side
may have a workspace dir of:
C:/Documents and Settings/My User/workspace
and lets assume you went ahead and just mounted the windows user home
as your linux user home, then the workspace on that side would be
something like:
/home/myuser/workspace
The first thing the eclim client will do is ask the server for a list
of projects for each workspace (including paths etc) and store that
info in memory. Then to determine the project for a give file, it will
compare the file's path to each project path until it finds a match,
but for a file on your linux machine located at
/home/myuser/workspace/myproject/Foo.java, the project path
C:/Documents and Settings/My User/workspace/myproject isn't going to
match, so the client will assume there is no project for the file.
This same scenario will play out in different ways but it's all the
same root cause. The only way currently I could see setting up the
daemon on a separate machine would be if both the daemon side and the
client side are of the same family (Linux, Windows) and that the home
directory is a straight mount at the same location for both the server
and client.
--
eric
Thanks Eric for the quick and thorough response. Ultimately I was
able to create a script that called "eclim --nailgun-server <winhost>
-command problems" directly, convert the Windows-centric file names to
something valid on Linux, then import into a vim quicklist.
Thanks so much for your effort on eclim. It makes programming in
(spite of) eclipse much more tolerable.
Steve
That's one way to solve it ;)
> Thanks so much for your effort on eclim. It makes programming in
> (spite of) eclipse much more tolerable.
>
> Steve
My pleasure. You're not the first person to want a multi machine setup
(though the first want it with differing OSes), so as I get time I'll
be incrementally improving eclim to make multi machine usage at least
a bit easier.
--
eric