To run all the tests in a single file, right-click the test in the Project Pane (the left-hand navigation pane), and select Runhttps://blog.jetbrains.com/phpstorm/2017/01/working-with-phpunit-and-phpstorm/
. To run all the tests in a single class, right-click the class name in the editor, and select Run . To run the tests in a single method, right-click the method name, and select Run .
At Spatie we use GitHub for both our client projects as our open source code. So in our day to day work we often have to open the browser to view issues of a repo or review pull requests. Paul Irish, a well known developer and part of the Google Chrome team at Google, made a nice bash script to quickly open up a GitHub page from your terminal. If you're on a path inside a git repo and type "git open" that'll open up the corresponding page on GitHub. The command also supports, amongst others, repos hosted on GitLab.com and Bitbucket. https://github.com/paulirish/git-open
Mohamed Said peeked behind the curtains and explains on his blog how Laravel Valet works behind the scenes.
The idea behind Valet is that it configures PHP's built-in web server to always run in the background when the operating system starts, then it proxies all requests to a given domain to point to your localhost 127.0.0.1http://themsaid.github.io/magic-behind-laravel-valet-20160506/ If you want to keep Homestead around for some projects, know that your can also use dnsmasq to point an entire domain to your Homestead installation.
Chances are that if you've been following the news in the Laravel ecosystem that you've heard of Laravel Valent. If not: Laravel Valet is a super easy way to serve your sites in a development environment. It's dead simple to setup and use. Here's the intro video: https://www.youtube.com/watch?v=H3Z4Gk9Wc0s I think it's kinda amazing that it was built in just four days. Not everybody is a fan of the Valet approach be I sure do like it. At Spatie, we're going use Valet instead of Vagrant for most of our projects. Need to know more about Valet? Check out this post on dotdev.co and the official documentation.
Transfer.sh is a free service by Dutchcoders that allows you to easily share files from the command line. Here's an example of how you can use it:
The given file will be uploaded to the transfer.sh-servers and the command will respond with a short url linking to that file. Pretty neat! The only thing you need to do is set up a bash function called "transfer" (you can name it anything you want really). Don't trust the transfer.sh with your supersecret files? Then you can set up your own server to transfer the files to.
PHPStorm is the application I'm working in most of the time. So I want it to be as pretty as it can be. Right out the box PHPStorm contains two bat shit ugly themes: the default white one and the slightly better Darcula. Fortunately for all PHPStorm users out there long time Laravel community member Dayle Rees showed us the way to the light! A few years ago he created an abundance of colour schemes that are a pleasure to the eye. You can view all the schemes on the demo page. More recently Dayle created a new colour scheme called Material Peacock. This is what it looks like: Very nice! Almost everywhere I open up PHPStorm people ask what that theme is, so I'm certainly not the only one who digs it. At this year's PHP UK Conference a PHPStorm-engineer from Jetbrains said it was the most beautiful theme he ever saw in his own product. You find instructions on how to install the theme (made by Chris Magnussen) and the colour scheme in Dayle's Material Peacock repo on GitHub.
A few days ago Toon Verwerft gave an uncon talk at PHP Benelux Conference about a new code quality checking tool he has been developing. It's called GrumPHP. It can automatically perform various code quality checks when you try to commit some code.
Sick and tired of defending code quality over and over again? GrumPHP will do it for you! This composer plugin will register some git hooks in your package repository. When somebody commits changes, GrumPHP will run some tests on the committed code. If the tests fail, you won't be able to commit your changes. This handy tool will not only improve your codebase, it will also teach your co-workers to write better code following the best practices you've determined as a team.https://github.com/phpro/grumphp The slides of Toon's talk can be found on speakerdeck.
Jack McDade, who designed the laravel.com and laracasts.com sites, shares some tips on how to make composer and npm much faster.
Whenever I runhttp://jackmcdade.com/blog/tired-of-waiting
npm installI feel like an old man yelling at young punks to get off my lawn. Especially ever since
npm3. I’ll save you the bitter diatribe and just get to the solution. But first, the problem. Creating, distributing, maintaining, and consuming third-party dependencies was supposed to make us more productive and our lives easier. Instead, I feel like I spend more time waiting than coding. So I dug and dug until I found solutions, as one does, and now I’m sharing them with you.
httpie is a command-line http client, much like cURL or wget. Written entirely in Python (using requests for the backend and pygments for syntax highlighting), it’s well portable to many platforms, including the big three Windows, Linux and OSX.http://radek.io/2015/10/20/httpie/
Having documentation on your API is highly beneficial. If it is well written you're likely going to receive less questions by consumers of your API about how it works. Aglio is a nice tool that I've been using to generate API documentation. In goes the Markdown, out comes the beautiful documentation.
GoAccess is an open source real-time web log analyzer and interactive viewer that runs in a terminal in *nix systems. It provides fast and valuable HTTP statistics for system administrators that require a visual server report on the fly.
Supercharge OSX' Quick Look with these plugins: https://github.com/sindresorhus/quick-look-plugins You can opt to install them manually, the cool kids prefer to do this with Homebrew Cask.
I didn't know, until a colleague mentioned it today, PhpStorm offers a clipboard history. On the mac press
cmd+shift+vto invoke it. By default it only stores the last 5 copied items, but you can increase that number in the preferences. Very handy!
Duet is the first app that allows you to use your iDevice as an extra display for your Mac using the Lightning or 30-pin cable.http://www.duetdisplay.com/ Very cool, almost no lag, works as advertised.