Developer Tools
PHM has a built-in tool manager. You install developer tools the same way you install PHP packages — with phm install.
Available Tools
Section titled “Available Tools”| Tool | Description | Install command |
|---|---|---|
| composer | Dependency Manager for PHP | phm install composer |
| symfony | Symfony CLI — build, run, and manage PHP applications from terminal | phm install symfony |
| phpstan | PHP Static Analysis Tool | phm install phpstan |
| php-cs-fixer | PHP Coding Standards Fixer | phm install php-cs-fixer |
| psalm | Static Analysis Tool by Vimeo | phm install psalm |
| laravel | Laravel Installer | phm install laravel |
| deployer | Deployment tool for PHP | phm install deployer |
| castor | DX-oriented task runner | phm install castor |
Installing Tools
Section titled “Installing Tools”Tools are installed to /opt/phm/bin and managed separately from PHP packages:
# Install Composer and Symfony CLIphm install composer symfony
# Install PHP and tools togetherphm install php8.5-cli composer phpstan
# Force reinstall (upgrade)phm install composer --force
# List installed packages and toolsphm listTools are installed globally and available immediately in your terminal (if /opt/phm/bin is in your PATH).
Composer
Section titled “Composer”phm install composerPHM downloads composer.phar from getcomposer.org and creates a wrapper script that uses PHM’s PHP automatically. No manual curl or mv needed.
composer --versioncomposer installcomposer require some/packageSymfony CLI
Section titled “Symfony CLI”phm install symfonyThe Symfony CLI is a developer tool to help you build, run, and manage your PHP applications directly from your terminal. PHM downloads the binary for your platform from GitHub releases.
While designed for Symfony, it works great with any PHP project — Laravel, WordPress, or plain PHP. Key features:
- Local web server with automatic HTTPS and HTTP/2
- Per-project PHP version via
.php-versionfile —symfony phpautomatically uses the right version - Proxy for accessing projects via local
.wipdomains - Integration with Docker, SymfonyCloud, and platform.sh
# Start local serversymfony server:start -d
# Use project-specific PHP version (reads .php-version)symfony php -vsymfony composer install
# Works with any PHP project, not just Symfonycd my-laravel-appecho "8.4" > .php-versionsymfony php artisan serveSee Version Switching for details on per-project PHP version management.
PHPStan / Psalm / PHP CS Fixer
Section titled “PHPStan / Psalm / PHP CS Fixer”These tools are installed as Phars via Composer, managed by PHM:
phm install phpstanphm install psalmphm install php-cs-fixerPHM handles the entire process — downloads the tool via Composer in an isolated directory, extracts the phar, and creates a wrapper script pointing to PHM’s PHP. No need to configure ~/.composer/vendor/bin.
phpstan analyse src/php-cs-fixer fix src/psalmLaravel / Deployer / Castor
Section titled “Laravel / Deployer / Castor”phm install laravelphm install deployerphm install castorlaravel new my-appdep deploycastor task:runManaging Tools
Section titled “Managing Tools”# List all installed toolsphm list
# Show available toolsphm list -a
# Remove a toolphm remove phpstan
# Show tool infophm info composerPEAR / PECL
Section titled “PEAR / PECL”PEAR/PECL is available as a PHP package:
phm install php8.5-pear