dbrekelmans/bdi
Composer-installable PHAR for Browser Driver Installer. Automates downloading and managing browser drivers (e.g., ChromeDriver/GeckoDriver) for PHP test setups. Releases are built automatically via GitHub Actions; contribute to the main tool repo.
Start by requiring the package via Composer:
composer require --dev dbrekelmans/bdi
This installs the browser-driver-installer PHAR as a Composer executable (vendor/bin/bdi). Run it once to see available commands:
vendor/bin/bdi list
The primary use case is automating browser driver (e.g., ChromeDriver, geckodriver) installation for browser automation tools like WebDriver (Selenium, PHP WebDriver) or testing frameworks (Laravel Dusk, Behat). Run vendor/bin/bdi install to download and place the latest compatible drivers in ~/.bdi/drivers.
vendor/bin/bdi install in your CI pipeline before browser tests run (e.g., in before_script or steps), ensuring up-to-date drivers without hard-coding versions.vendor/bin/bdi to your composer.json scripts section for team consistency:
"scripts": {
"bdi:install": "@php vendor/bin/bdi install"
}
Then run composer bdi:install before testing locally.dusk-updater or custom Artisan commands; for example, create php artisan dusk:drivers that calls exec('vendor/bin/bdi install').~/.bdi/config.yml):
drivers_dir: "/path/to/project/drivers"
allow_url_fopen is enabled and phar wrapper is not disabled in php.ini; otherwise, vendor/bin/bdi may fail silently.--arch flag might be needed: vendor/bin/bdi install --arch=arm64.vendor/bin/bdi install --browser-version=118 to lock driver versions matching your browser environments.-vvv for verbose output to inspect download URLs, HTTP status codes, and system environment checks.~/.bdi/config.yml. Use it to set default options (e.g., auto_update: true) or custom driver source mirrors for air-gapped environments.How can I help you explore Laravel packages today?