Running PHPUnit tests over SSH on Vagrant with PhpStorm 8

More and more PHP developers are shifting to a workflow where they use PhpStorm on their local machine and run and debug their PHP applications on a remote server or Vagrant machine. Which is great! Every project we’re working on would have its dedicated, virtual development machine and we easily share the project configuration and development environment with our team. Even version it through source control.

Since introducing Vagrant support in PhpStorm 7, we’ve had tons of feedback from our users. While PhpStorm has been supporting running PHPUnit on remote servers for quite a while, developers working with Vagrant clearly prefer doing this over SSH instead. And that is exactly what we can now do using PhpStorm 8.

Running PHPUnit tests on Vagrant using PhpStorm

Head over to our tutorial on running PHPUnit tests over SSH on Vagrant (or remote servers) and give it a go with the latest PhpStorm 8 EAP. Your feedback is welcome through the issue tracker, by posting in the comments below, or in our forums!

Develop with pleasure!
– JetBrains PhpStorm Team

Posted in Cool Feature, Early Access Program | Tagged , , , , , , | 4 Comments

PhpStorm 8 EAP 138.1161

PhpStorm 8 EAP 138.1161 is available for download.

From the PHP side, this build delivers:

  • Fluent-style chaining type loss with return this/static fixed, and many other PHP language related issues are resolved
  • Wrapping for comments on code reformatting is added
  • PHP 5.6 support improvements
  • Multiple stubs fixes
  • Behat: Search for all classes in project that extends BehatContext (for 2.*) or implements Context (for 3.*) to find step definitions
  • Behat: recognition of multiple patterns
  • Add PHPDoc comment intention and other actions generating @var annotation now allow to use @type instead of @var (option in Settings | Code Style | PHP | PHPDoc called Generated type tag)
  • many bug fixes and improvements (see full list in our issue tracker)…

All the IntelliJ platform (e.g. the Open action from the welcome screen now opens single files) and web changes (e.g. emmet filters) are also included.

See full release notes for a list of changes.

Download PhpStorm 8 EAP build 138.1161 for your platform from project EAP page and please report any bugs and feature request to our Issue Tracker.

Patch-update will be available within an hour from the previous EAP build (PhpStorm 8 EAP 138.940).

*Update* If you experience any problems with this build (e.g. Symfony2 plugin issue) please download the previous version (PhpStorm 8 EAP 138.940) from the PhpStorm EAP page archive.

Develop with pleasure!
-JetBrains PhpStorm Team

Posted in Early Access Program | Tagged | 21 Comments

PHP Mess Detector in PhpStorm

PHP Mess Detector in PhpStormPhpStorm comes with many inspections that help us analyze and improve the quality of our codebase. By using PHP Mess Detector (PHPMD), we can enable many additional code quality checks on our codebase: it can detect possible bugs, suboptimal code, unused parameters and so on. In other words: it tells us if our code is worthy of seeing the daylight. PHPMD also contains several rules that check for complexity of code and will tell us if we should rewrite our code into something that is more maintainable. All these checks are integrated nicely in PhpStorm. Let’s have a look at some examples!

Continue reading

Posted in Cool Feature | Tagged , , , , , | 9 Comments

Be Awesome in PhpStorm Course at Laracasts by Jeffrey Way

laracasts_logoAll series of the video course Be Awesome in PhpStorm are now online at Laracasts and available for free! Thanks a million to Jeffrey, the author of this great courseware.

The course consists of 24 episodes. Most of the course is not Laravel-specific, so it’s recommended to all PhpStorm users.

Be Awesome in PhpStorm

Think about how many hours each week you spend within your editor. Doesn’t it make sense to unlock every inch of its capabilities? I certainly subscribe to that idea! Why don’t you come along, and I’ll teach you everything I know about PhpStorm.

- Jeffrey Way, Laracasts

Continue reading

Posted in Screencast | Tagged , , | 12 Comments

New Live Console in JavaScript and Node.js debugger

Some features are so (seamingly) simple yet so powerful. One of them is the new Live Console in the PhpStorm JavaScript and Node.js debugger. While debugging JavaScript, we can use the Console tab to execute arbitrary JavaScript code within the execution context. This means we can alter variables, call JavaScript functions, or even define additional functions on the fly.

Live JavaScript console

This feature is available in the latest PhpStorm 8 EAP. Give it a try and let us hear your thoughts! All feedback is welcome through the issue tracker, by posting in the comments below, or in our forums!

Develop with pleasure!
– JetBrains PhpStorm Team

Posted in Cool Feature, Early Access Program | Tagged , , , | 7 Comments

PhpStorm 8 EAP 138.940

PhpStorm 8 EAP 138.940 is available for download.

From the PHP side, this build brings:

  • PHP 5.6 support is added (exponentiation, use const, use function, constant expression, variadic functions, argument unpacking). There are some PHP 5.6 related issues in progress, make sure to have a look in the issue tracker before reporting problems. See WI-22263 for details.
  • New formatting option: Convert long to short array syntax
  • Improved UI for Remote Interpreter configuration
  • many bug fixes and improvements (see full list in our issue tracker)…

IntelliJ platform and web changes are also included.

See full release notes for a list of changes.

Download PhpStorm 8 EAP build 138.940 for your platform from project EAP page and please report any bugs and feature request to our Issue Tracker.

Patch-update will be available within an hour from the previous EAP build (PhpStorm 8 EAP 138.826). *Update* We’ve fixed the issue with Mac OS patch, and re-uploaded it. Patches are OK now for all platforms. Sorry for inconvenience.

Develop with pleasure!
-JetBrains PhpStorm Team

Posted in Early Access Program | Tagged , | 45 Comments

PhpStorm 8 EAP 138.826

PhpStorm 8 EAP 138.826 is available for download.

From the PHP side, this build brings:

  • Folding for classes
  • New formatting option: Settings | Code Style | PHP | Spaces | Within | <?= and ?> (on by default)
  • Bunch of changes in language injections & run query in console functionality
  • many bug fixes and improvements (see full list in our issue tracker)…

IntelliJ platform brings everything introduced in recent IntelliJ 14 EAP:

  • The new Code cleanup action (available via Analyze → Code Cleanup or as an option in the VCS commit dialog) which applies quick-fixes in batch mode to selected files
  • Improved Find in path action, which now can search within files with unknown extensions and within the .idea configuration files. It also uses indices when searching for strings that contain a part of an identifier (3 characters and longer)
  • Copy/paste selected code as HTML/RTF is now available without additional plugins
  • Better IDE startup time

Read more about IntelliJ IDEA 14 EAP.

Web changes include postfix code completion for JavaScript, Spy.js and Node.js now can run together via new run configuration, and more.

See full release notes for a list of changes.

Download PhpStorm 8 EAP build 138.826 for your platform from project EAP page and please report any bugs and feature request to our Issue Tracker.

Patch-update is not available this time, we are sorry for inconvenience. PHP plugin for IntelliJ IDEA has been updated to be compatible with IntelliJ IDEA 14 EAP.

Develop with pleasure!
-JetBrains PhpStorm Team

Posted in Early Access Program | Tagged , | 15 Comments

Debugging PHP and JavaScript code at the same time

Debugging JavaScript and PHP with PhpStormWhen developing PHP applications for the web, chances are we’re also using a good amount of JavaScript with it. Using PhpStorm, we can debug the PHP code running on the server and inspect what is happening while it’s running. We can also debug the JavaScript running in the browser by starting a JavaScript debugging session from our IDE. But what if we want to do both at the same time? Is that even possible? Well, yes, it is! Here’s how. Continue reading

Posted in Cool Feature | Tagged , , , , | 3 Comments

Announcing Grunt support in PhpStorm 8 EAP

Grunt in PhpStormWe are pleased to announce Grunt support in PhpStorm 8 EAP! If you’re new to Grunt, it is a JavaScript Task Runner, much like Phing is for PHP, which can automate a lot of tasks in our development workflow. Grunt has a large number of plugins available that can automate anything from minification and compilation to unit testing, linting and so on. Let’s see how we can get Grunt to work in our favorite IDE! Continue reading

Posted in Cool Feature, Early Access Program | Tagged , , , , , , , | 18 Comments

Using PHP Code Sniffer in PhpStorm

Team members may have different backgrounds and code style preferences. In code bases where no formal code style is used, it can become obvious who wrote which code because of different styles being used. Having to work on such code base comes with some drawbacks: developers have to continuously switch their mind around reading code because sometimes brackets are on a new line, sometimes not. Sometimes brackets are required, sometimes not. To ensure a natural flow working with code, a coding standard can be enforced so that the entire code base becomes more uniform to read and work with.

In PhpStorm, we can configure code style through Project Settings | Code Style and use one of the many available schemes. There are also various inspections that check our code against the code style. We can add additional code style inspections to PhpStorm using tools like PHP Code Sniffer. By inspecting PHP, JavaScript and CSS files PHP Code Sniffer will warn us whenever violations are encountered against coding standards like PEAR, PHPCS, PSR1, PSR2, Squiz, Zend and many others like WordPress, Drupal, Symfony2 and so on.

PHPCS in action

Did you know PhpStorm comes with PHP Code Sniffer integration, displaying its warnings and errors right in the IDE? Read our tutorial on PHP Code Sniffer in PhpStorm to find out more.

Your feedback, comments and suggestions are welcome through the issue tracker, by posting your comments below or in our forums!

Develop with pleasure!
– JetBrains PhpStorm Team

Posted in Cool Feature | Tagged , , , , , , | Leave a comment