Switching to PhpStorm

A few months back I retired Sublime Text from my day to day coding and have since switched to using PhpStorm as my go to editor. I do keep Sublime around for quick editing, writing blog posts, but I haven’t missed it otherwise. PhpStorm has a lot of nice features that you don’t realize sublime is missing until you switch. Here is my mini review on what I’ve found in the few months of using PhpStorm.

Git and Github

I have found the git and github integration brilliant. I really like opening issues right in the ide and it creating a new branch/workplace. At UserScape we do a lot with Trello and only use GitHub Issues for bugs so I don’t get to use this as much I would like. Maybe one day some one will integrate Trello. 🙂

Committing is also something I really like doing without having to leave my editor. It has this integrated via command + k. Or if you are old school you can just open the terminal tab. My personal preference is to visually commit so I only use the terminal when I have small changes.

Find Anything

Another huge feature is the search everywhere. I have this mapped to “command + t” to match Sublime but the original is a Double-Shift. This is way more powerful than Sublime though. You can find files, classes, actions and preferences. I really like the actions searching because I have a mental block and can never remember them. This is probably why I don’t enjoy VIM or anything else that requires me to learn key maps. As an example I like splitting the window so I just “command + t” type vertical and BAM the action shows and it splits. Maybe I want to diff the file, again command + t type annotate. These are huge time savers for me.

Terminal

The terminal integrated is brilliant. We use grunt for all our js and css and have a simple watch/reload task. So when I start editing I just open terminal run grunt watch and then open a new terminal tab for anything else I may need. Deploying, artisan, composer, etc.

Code Complete

PHP code completion is very nice but believe it or not I find the code complete in html and less way more beneficial. It works just as nice as the php auto complete and does a very good job filtering css classes to find the one you want without having to hunt it down. It also has great support for CoffeeScript (The ONLY way to write JS). 🙂

Themes and Interface

This is one area I do find frustrating at times. The default theme is Darcula and it is a huge improvement over previous versions and you can find a ton of themes at PhpStorm-Themes or my recent favorite Spacegrey. What frustrates me is the font adjustment and line-heights. Fonts typically look good at bigger sizes but when you set the size to 10 or 11 they just don’t feel crisp like Sublime. The line height is also crazy. You set it to 2.0 and then you get a monstrous cursor.

Tips

If you are currently using Sublime and want to try PhpStorm here are some tips I have. I would hide all the panels and just move in slowly. I started with just as a code editor and then slowly experimented with features until I found my ideal workflow. It has a huge number of features that I don’t understand and/or haven’t cared to fully investigate.

Expect it to be slower than Sublime. A lot goes on under the hood for finding things, auto completing, etc and it’s always going to be slower than sublime. I only really notice this at times but that first launch you will.

Laravel is my framework of choice and the code completion doesn’t work great with the facades. A work around is to add this composer package

"require-dev": {
    "barryvdh/laravel-ide-helper": "1.*"
},

Next go and watch some videos and read some posts that highlight features and show you tips you would otherwise miss.

All in all so far the features outweigh the annoyances I have so I am going to stick to using it for the foreseeable future. Big IDE’s aren’t for everyone, but I encourage you to give a PhpStorm a chance. I think you might just like it.

Switching to PhpStorm

0 thoughts on “Switching to PhpStorm

  1. Pablo Ezequiel Leone Signetti says:

    Just an hour or so…

    My custom commands in my .profile file don’t work on the Phpstorm Terminal.

    The SSH commands saved on PhpStorm can’t be triggered by a shortcut, and they are not available on its Terminal.

    I couldn’t even connect to my local DB, this is the help I found for my issue http://stackoverflow.com/questions/6865538/solving-a-communications-link-failure-with-jdbc-and-mysql. I DON’T WANT TO TRY ALL THAT!

    I started with the style configuration and I noticed that its tooooo much!!

    Spaces, new lines, etc. Phpstorm prioritise configuration over convention, very annoying. And I just tried to amend PHP styles.. uff!

    SVN is not integrated, just git and mercurial.

    Mercurial projects don’t work, there is an issue with the hg command on my environment, which I’ve never noticed with other tools and they can deal with that. I don’t understand.

    Sublime Alignment, I couldn’t find a way to do anything similar.

    I tried to install a plugin like angularjs extension. I couldn’t find an easy step by step or guide that help me out on how to intall or move the jar file I downloaded.

    The go to definition, doesn’t work for angularjs (I know is javascript, but works in sublime as well as php), nor for ExpressionEngine, just basic php files.

    I was crazy when I decided to try the debugging system. No way, too much configuration, too difficult, more than my actual code. In sublime I spend an hour following the plugin guide and done.

    Code highlighting in Sublime is much easier to read and its consistent.

    When you switch panels at the bottom, the event log panel changes to show you random events relevant to the actual panel you switched on. Interesant but ugly, I don’t want the IDE to be that clever, sometimes I can’t see whats going on, I’ve a 27 inches screen in front of me.

    cmd+z doesn’t work for all tasks. If you inject language (I don’t know what is that) you can’t undo that action with that shortcut.

    Open two files with the same name at the same time, the first file tab title is not updated, how is suppouse for me to know which file it is.

    I had enough!

    I’ll stay with Sublime.

Leave a Reply