tags:

views:

136

answers:

11

Suppose I have a server that runs on Linux on which I would like to develop software (mainly OCaml, C/C++ and Java).

Is there a way to "remote develop" these things? I mean an IDE that allows me to modify files remotely (they are then uploaded when modified and saved) and to compile through SSH (basically invoking make or omake).

I was looking for something that makes this process transparent to the developer, without caring of doing things by hand. I'm used to use Eclipse so I wonder if a plugin to achieve this exists or if are there other choices?

Mind that it may happen that the local machine it not able to build software I intend to (for example for OCaml) so it should rely just on remote connection.

Thanks in advance

+2  A: 

Well the simplest idea I can think of, though it is rather brute force would be to just open up a file share to the server and then edit the file directly through Eclipse.

If that doesn't work for Java at least you could make use of Maven to do some of those tasks. I am less certain about invoking Make though.

Matt
+3  A: 

You can use X11 forwarding. Even if you are connecting from a Windows machine.

If you are on Linux, connecting with ssh -Y might work right out of the box for you:

ssh -Y user@your_server
eclipse &
karlphillip
+1  A: 

Depending on how 'remote' this is; why not ssh in and run the IDE remotely over X?

qor72
No, I don't want to run the IDE remotely, I want to save files and compile them remotely..
Jack
@Jack - An automated build process that is watching for changes in the file system?
qor72
It mustn't be automatic, just something like: I edit source, I save them and it automatically send updates to remote server, I "click the compile button" (just to give the idea) and it compiles it remotely. I don't need any kind of GUI response for now, just being able to execute the compiled program and see the output. Maybe I'm looking for a ssh-wrapper :)
Jack
I could see you extending Eclipse to do something like that. Just not sure on the utility of it. Feels like a remote build server?
qor72
A: 

I use vim for remote development. (Well, I use vim also non-remote.)

swegi
+1  A: 

Using a build tool (Hudson for example) you could put a build agent on your remote server, check your changes into your repository as normal, and have it do a build when you check in changes (it will either do a repository hook or poll for changes, probably). Your build process will be the same, it will simply be automated. :-)

glowcoder
Having to check code in before I can compile and test my changes seems backward to me.
Rob Kennedy
If you're the only one working on it (which it seems to be from what you're saying) it wouldn't really be a problem. You're right, it is a little backward, but with this system in place it lends itself to extension later.
glowcoder
A: 

If building is the problem, have you thought about simply using an automated build system where you commit to svn and the system then automatically builds the software? I've heard many good things about these sorts of systems, although I haven't quite tried any out myself.

As for remote development, a SVnDAV solution might be reasonable. It basically commits your every save and is completely transparent to the text editor you're using. However a probably much nicer solution would simply be to use a networked drive/directory and edit files remotely. On all unix-based systems this should work completely transparently to both the developer and the text editor.

Swizec Teller
A: 

emacs has tramp, which lets you both open and save remote files, and open a shell on a remote system. Working with tramp is almost exactly like working with local files, except for the filename. To open 'foo.c' on the machine 'bork' as user 'joe' I open it with the standard emacs commands, giving it the pathname /joe@bork:foo.c

Bryan Oakley
A: 

Your choice of IDE will have the most impact on the answer to "can I?". If your IDE of choice is CLI based than you can always just SSH in, fire up screen (so that your CLI session is persistent across SSH sessions), and have at it!

STW
A: 

I think your answer is IDE-centric.

KDE's ioslaves support access over both SFTP and SSH (using fish, which uses a Perl script uploaded to the remote machine). I believe Gnome also has a virtual file system (gvfs) which supports remote filesystem access.

My recommendation, therefore, is to choose an IDE which supports a virtual filesystem that can operate over SSH/SFTP and allows you to specify the build command. You would then only need to specify the build command which would get its output from the remote make command (for example, vim has a makeprg option which can be set to any arbitrary command).

Kaleb Pederson
A: 

Use vim or emacs since they will offer you speed. I know there is a learning curve associated with these editors; but once you get comfortable in any of them; you will be able to work on them as good as with Eclipse or any other IDE.

Deepank Gupta
A: 

If you already have a linux server then I would suggest setting up a simple VPN server. I have done this in the past and it works pretty well. This way you can connect and modify/build your files with any "local" OS. I did this cause I use mac, pc and linux through various parts of the day and in multiple locations, so the VPN allowed me to edit files remotely w/out having to allow file sharing over the internet.

There are plenty of tutorials about how to achieve this even if you are newer to linux. I use ubuntu server on my linux box and here are the tutorial I have used.

http://www.ubuntugeek.com/howto-pptp-vpn-server-with-ubuntu-10-04-lucid-lynx.html

stmpy