nunomaduro/phpinsights
PHP Insights is a terminal tool to analyze PHP code quality, style, architecture, and complexity. Works out of the box with Laravel (artisan insights), Symfony, Yii, Magento, and more, with built-in checks for reliability and loose coupling.
Since <Badge text="^1.10"/> version of PhpInsights, you can add links to files in PhpInsights output.
Links in terminal work thanks to symfony/console
from 4.3 version. Be sure you are using this version with composer info symfony/console.
If your terminal does not support hyperlinks, they will be rendered as normal and non-clickable text.
That's why it's recommended to check out the list of terminal emulators that support hyperlinks.
In your phpinsights.php file, add the config 'ide' => 'myide'.
For example:
<?php
return [
// ...
'ide' => 'vscode',
// ...
];
You can fill ide config with the followings values:
::: tip About PhpStorm The phpstorm option is supported natively by PhpStorm on MacOS.
Windows requires PhpStormProtocol and Linux requires phpstorm-url-handler.
You may also have to enable the command-line launcher. :::
If you use another editor, the expected configuration value is a URL template
that contains an %f placeholder where the file path is expected and %l
placeholder for the line number.
For example:
<?php
return [
// ...
'ide' => 'myide://open?url=file://%f&line=%l',
// ...
];
How can I help you explore Laravel packages today?