Category Archives for laravel

Add pint to PHPStorm File Watchers

Open your settings in PHPStorm and go to Tools > File Watchers

Add a new Custom File Watcher and use the following information:

Name: pint
File type: PHP
Program: $ProjectFileDir$/vendor/bin/pint
Arguments: $FileRelativePath$
Output paths to refresh: $FileRelativePath$
Working directory: $ProjectFileDir$

Add url to your laravel Exception context

props to @_newtonjob

// file app/Exceptions/Handler.php
class Handler extends ExceptionHandler
    public function register(): void

    public function context()
        return array_merge(parent::context(), [
            'url' => url()->full(),
            'method' => request()->getMethod(),