Your most changed file

A little fun for cloudy summer days. The theory is to find files in your project that have the most changes. Could this class or file be refactored to be...

Laravel Forge Menubar

Laravel Forge is a tool for deploying and configuring web applications. The makers of the Laravel framework developed it, but you can use it to automate the deployment of...

Laravel Forge, where are the rewrite rules?

If you are using Laravel Forge and want to have a debug at a site’s rewrite rules, this is their location: /etc/nginx/forge-conf/mysite.com/server/redirect_rules.conf Notes Don’t change them manually;...

Nginx rewrite rules and match only beginning of string

A nice little gotcha. Often when you write Nginx rules, you forget that it matches everything in the string. Imagine if you want this redirect /product-a -> /category-1/product-a

Test event inside an Eloquent observer

Most times you test that events are fired by adding Event::fake() to your tests. This will make Event::assertDispatched(SomeEvent::class) to return true. However, no events will trigger as soon...