Pools
A simple and fast implementation of a thread pool in PHP
#Pools PHP
Pools is a CLI tool that helps you install and configure modern PHP development tools for your projects with a single command.
Requires PHP 8.3+
#What Pools Does
Pools v0.0.3 provides a seamless way to install and configure popular PHP development tools:
- 🧹 Pint: PHP code style fixer based on PHP-CS-Fixer
- ⚗️ PHPStan: Static analysis tool for finding bugs before they reach production
- ✅ Pest: An elegant PHP testing framework with a focus on simplicity
- 🔄 Rector: Automated refactoring tool to improve your PHP code
Each tool is installed with sensible default configurations, saving you time and ensuring consistent code quality across your projects.
#Installation
Install Pools globally using Composer:
composer global require poolsphp/pools
Make sure to add Composer's global bin directory to your PATH to run Pools as a shell command.
#For Bash/Zsh users (Linux/macOS):
Add the following line to your ~/.bashrc, ~/.zshrc, or ~/.bash_profile:
export PATH="$PATH:$HOME/.composer/vendor/bin"
Then reload your shell configuration:
source ~/.bashrc # or ~/.zshrc or ~/.bash_profile
#For Windows users:
Add the Composer's global vendor bin directory to your PATH environment variable:
%USERPROFILE%\AppData\Roaming\Composer\vendor\bin
#Usage
Navigate to your PHP project's root directory and run:
pools install
You'll be prompted to select which tools you want to install:
- PHPStan
- Pest
- Pint
- Rector
#Using specific tools
After installation, you can use the tools through Composer scripts in your project:
# Run PHP code style fixes composer lint # Run automated refactors composer refacto # Run static analysis composer test:types # Run unit tests with Pest composer test:unit # Run the entire test suite composer test
#CLI Options
Install all tools:
pools install --all
Install specific tools:
pools install --phpstan --pest pools install --pint --rector
Set PHPStan level:
pools install --phpstan --type-check-level=8
#Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
#License
The MIT License (MIT). Please see License File for more information.