My developing environment doesn't seem to fit with phpStorm - suggestions

A bit of history.  Used to do all php development on a linux box using vim (without X installed).  Once I started I working on larger projects with others code, I wanted to take advantage of a debugging tool to help me through their code.  I started using various IDEs on a Windows box but all the code still remained on a remote linux host as it was important to have our development box almost identical to the production environment.

Fast forward to today, I am running a win7 desktop and my development environment is a debian VM running on the same box with a windows fileshare so I have easy access to the files on either system.  I've been using Netbeans and xdebug works fine but could never get utilities like composer, artisan, or phpunit to run remotely through the IDE so I've just kept an SSH window open to handle those.  The problem is when I run those utilities Netbeans did not know some files changed externally.  I have to manually do a sync and it has occassionally crashed corrupting the entire project (not the actual files) but that still meant copying the files, deleting the project, restoring the files and reconfiguring the project from those files.

I do a fair amount of graphic work so I prefer to keep my primary workstation running win7 and I still prefer my development webserver to be as close to the production server as possible (well it 100% identical except the development box also runs samba for filesharing)

I'm told phpStorm is the answer to my problems but as best as I have been able to figure it out, phpStorm doesn't actually work on the remote servers files and instead works on a copy of the remote files.  So I run into the same issues if I run artisan for example to create a bunch of new files - phpStorm doesn't seem to know until I resync (same issue as Netbeans).  Even worse however is phpStorm isn't working with xdebug in this environment as it tries to pass the local win7 file path to the linux server which of course it doesn't understand the path.  It is using the remote servers interpreter as I have no php installed locally and I'm sure that is where the glitch is.

I've been told to use Vagrant however I have VMware Workstation on my desktop becaues I manage a couple clusters of VMware ESXi servers and it is important for me to do testing and passing VMs to and from those clusters so it must stay and Vagrant caused problems with it so I had to abandon the Vagrant option.

Another less ideal option is to install X on the linux box and use PHPStorm directly on that box but it means jumping between the Vm and my workstation each time I want to do graphic work.  Anyone else in this situation with any suggestions on how I should set up my environment?

Comment actions Permalink

I am in a similar situation as you and also hoping to find a way to harness the power of phpStorm. Only my site is running Magento, which could be among the most miserable aspects of my world. :)

I'll pile on my plea for help to yours, as I feel our frustrations are related to each other.

Here's my current workflow:

1)  I ssh into the production server and mostky use grep -rin "problemClass" and find to locate classes and code browse.
2)  notepad++ can log in to the site so I can make direct edits to files, save them, test the site.
3)  using the command line, I update our github private repository with the changes.

I've been bangning my head against phpStorm for over a month now. Every time I begin a new wave of edits to files on the site, I'll fire up phpStorm and waste my first day on trying to make it work. Today is a new feature day for the site, so today's wasting away again.

One time. Once. I was able to get phpStorm to work. And I was able to Ctrl+S and get the change to reflect on the site. Never since. I've tried over 10 times. I've got something of a copy of my site on the LAN raid fileserver that phpStorm uses as the project. Since then, I have to make my edits in notepad++ then scp the files down to the LAN raid in order for phpStorm to work.

I read this post and eventually found the option for enabling Upload external changes. And now what? I hit the sync button. It just says "External file changes sync may be slow: Project files cannot be watched (are they under network mount?)" and then nothing. So now I have notepad++ and PuTTy open so I can get actual work done...

What does it take to use phpStorm and enjoy its awesome php class powers?


Comment actions Permalink

Playing with PHPstorm it has some really neat abilities but most only seem to work if PHPstorm is installed on the same system as the development box itself.  I ended up installing X on my development VM and installing PHPstorm there and then things just started to work as expected.  But most of that slickness doesn't do anything I really needed that I wasn't already doing on the command line.  The other problem is it runs incredibly slow on linux.  After digging through docs I found if I enabled OpenGL 3D on my VM and then switched my X environment (and PHPstorm) to take advantage of that and things got a great deal better but not quite as good as when running PHPStorm on Win7 or as my Netbeans development environment.  

If it wasn't for the rare corruption issue of a project in Netbeans I would still definately choose Netbeans over the two.  That said I've only been using PHPStorm for about 5-6 weeks now (got 30 days demo on Windows but just before I exhausted that I started using it on Linux) so I don't know if I'm going to switch and then 10 months down the road see the project file get corrupted regardless.  So I still have considerable hesitations.  The fact I got no useful feedback from the PHPstorm support community leaves me guessing either this support community is lacking, or perhaps remote development boxes for PHPStorm is a weakness and so no one likes to talk about it.  Basically in the end I'm just going to use the Linux version of PHPstorm until the license expires.  If by then (will be 60 days) if I find moving back to Netbeans awkward because I really started getting in to PHPstorm I'll be buying PHPstorm and otherwise I'll just roll back to Netbeans and hope the random (but very rare - like less than once a year) corruption of project files issue was finally fixed.


Please sign in to leave a comment.