I have been using PHPStorm for a few weeks and really enjoy it. I came here after using SublimeText 2&3 for the last few years, plus vim when I need to do something quick. But one of the big annoyances for me has been the need to double-click to open a file. Yeah, it’s kind of a silly thing to complain about, but I was very excited today to find the solution.
The fix is a strangely labelled option in the Project Files settings dropdown. Now I don’t mean in the main settings area, but rather from the gear icon in the Project View. In that dropdown you will find two magic options: Autoscroll To Source and Autoscroll From Source.
Turn both of these on and now a single click on a file opens it on the editor and selecting any open file highlights it in the project file list. Sweet!!!
Recently, I ran into a problem with libsass and loud comments. As some of you know I am working on building WordPress themes. At its bare minimum, a theme has a stylesheet with a comment at the top and a functions php file. I am using SCSS for styles and libsass to compile it.
While libsass does almost everything the regular sass command does, there are some things that are missing. Loud comments are one of the things that are broken right now.
I happen to use Codekit as well. Codekit watches a directory and then does what it needs to do to result in nice clean code. If there is anything Codekit doesn’t know about, you can run an extra command using a hook.
So I have Codekit take a style.scss file and compile it to style.css in the same subdirectory. Then I have a hook that watches for style.scss and runs the following shell script:
cat source/scss/template_about.scss source/style.css >style.css
This super simple script concatenates template_about.scss and style.css into a single new file. Note that the new file is in a new location. When I had it adding the text to the same file, Codekit looped forever.
The result of this is I get a SASS compile far faster than what the standard command provides and I automatically get a file that works for WordPress. Woohoo!!!