Has anyone managed to set up their IDE so that files saved to the local file system are automatically published to their server? For example, if I use Eclipse for PHP dev on a windows workstation, is there some way to set things up so that my PHP files are automatically copied to the Ubuntu server running on my LAN? I've considered Dreamweaver but it doesn't allow me to debug my PHP code. I've also used Eclipse on my Ubuntu machine and that works pretty well, but I'm hoping to use Flash Builder 4.5 (based on Eclipse) and unfortunately this product is not available on an ubuntu machine. I'm really hoping to avoid installation of any more daemon-type services on my windows workstation.

I think ideally it would be nice to network the two machines (SMB?) so that my windows desktop has an directory alias which allows me to save directly to a folder on the ubuntu machine. It's been my experience, however, that opening a file over a network is a good way to corrupt the file and experience real problems.

Can anyone recommend a two-machine PHP debugging setup where one is the workstation running the IDE and the other runs the LAMP stack?

    This may be well off-topic; I have Notepad++ on my workstation at my new job with an FTP plug-in. If you're connected to the FTP server with the plugin (and it supports SFTP via SSH, too), it saves a copy locally as well as to the path from which it was opened on the server ... you just have to open it from the server path window to make sure it behaves, and watch that the connection stays active.

    Pretty nice deal, considering all the time I was a "one man show" I just used NaNo in an Eterm or via PuTTY.

      I was going to suggest Dreamweaver or Eclipse, but I see you've mentioned both.

      Really, there are probably a lot of IDEs that integrate with some sort of version control system such as Subversion. It might be an extra step, but you could always install such a service on the LAMP machine.

        Your grit is laudable, Dale. I too have used nano and a bazillion echo statements directly on a server. My reason for the OP was that Flash Builder 4.5 (based on Eclipse) appears to offer all kinds of automatic code generation and data integration (not to mention code hinting, declaration lookup quick keys, debugging of both client and server code, etc.) which would likely reduce a LOT of the tediousness in coding and speed up my work. Admittedly, I am quite wary of auto-generated code, but I'd very much like to focus more on the high-level concept and less on the nuts-and-bolts of code.

        Not long ago I went through the trouble of setting up Eclipse as my IDE on an Ubuntu workstation. I found that it really sped up my development. In particular:
        save files to webroot on the local file system means instant availability on web server
        Eclipse offers quick keys to lookup declaration of functions, constants, etc.
        Eclipse offers code hinting and code completion, code formatting
        Eclipse integrates with both SVN and GIT
        I can debug my PHP code in either CLI or apache context -- no need to added echo or log statements to understand what is going on in code.
        separate machine for PHP dev means my windows desktop doesn't get bogged down with mysql daemon, apache, etc.

        I wasn't easy to get the debugging setup working, but I think it was worth it. The code hinting and lookup stuff is a real time-saver.

          bradgrafelman;10988751 wrote:

          I was going to suggest Dreamweaver or Eclipse, but I see you've mentioned both.

          Really, there are probably a lot of IDEs that integrate with some sort of version control system such as Subversion. It might be an extra step, but you could always install such a service on the LAMP machine.

          I once used dreamweaver and I do like how it offers simple version control on a mere FTP server, but was disappointed by its code formatting, lack of code hinting or lookup, etc. Maybe it's better now I dunno.

          Eclipse is pretty awesome, if not entirely user-friendly. I find one has to work pretty hard to get it configured for debugging, etc. and this is why I posted. I think your source control suggestion is a good one.

            Well, I'm seeing more of your thoughts as I read more thread. Have you thought about reversing the direction of the SMB share (I have no idea if this would work ... what if the webroot was on your local machine, shared to the server? I'm thinking that usually we'd think the other way 'round first).

            Next, what about virtualization? I'm using Oracle's VirtuBox to run a BSD server on my workstation ... FTP sync is pretty well instant, fo' shiz 😉

              Dale, that reversal of the usual SMB relation sounds pretty clever to me. I may ultimately try that.

              As it turns out, Flash Builder 4.5 appears to have a setting that lets you automatically upload your files to the server either via SSH or FTP/SFTP/whatever (q.v., File->Properties->Remote Server Support. NOTE that these settings are apparently project-specific). Still trying to figure out how to configure this properly. FB4.5 is based on Eclipse and if you've ever used Eclipse, then you know that there are a whole ton of configuration options that are not especially well-documented.

                Write a Reply...