PeckPHP is a command-line tool developed by Nuno Maduro that meticulously scans your codebase for potential mistakes in wording and spelling. It examines folder, file, and method names, along with comments and other elements. Seamlessly integrating into your existing workflow, PeckPHP complements tools like Pint and Pest, ensuring a consistent and professional codebase.
Note: Peck depends on GNU Aspell for its spell-checking functionality so you will need to ensure Aspell is installed on your system before using Peck.
To install Peck use Composer with the following command:
composer require peckphp/peck --dev
./vendor/bin/peck --init
And then to check your project for spelling mistakes, run:
./vendor/bin/peck
You can also configure Peck using a peck.json
file in the root of your project. In this file you can specify an available preset along with words and paths to ignore.
{
"preset": "laravel",
"ignore": {
"words": [
"config",
"namespace"
],
"paths": [
"app/MyFolder",
"app/MyFile.php"
]
}
}
Expand your development toolkit with PeckPHP and streamline the process of maintaining a clean and professional codebase. Learn more about PeckPHP and view the source code on Github.
The post PeckPHP – A CLI tool designed to identify wording or spelling mistakes in your codebase appeared first on Laravel News.
Join the Laravel Newsletter to get all the latest
Laravel articles like this directly in your inbox.
Source: Read MoreÂ