lexik/translation-bundle
Symfony bundle to manage translations in a database: import from xliff/yml/php, edit via a web GUI, track missing domain translations, add new keys, and export back to files. Database loader overrides file-based translations.
This document explains how to run the development tooling (tests, PHPStan, Rector, PHP-CS-Fixer) and how to do it cross-platform when make is not available.
The project uses a Makefile for convenience. You need GNU Make installed (it usually is on Linux and macOS).
make help # List all available commands
make ensure-up # Start Docker services and install Composer dependencies
make test # Run PHPUnit
make phpstan # Run PHPStan
make cs-fix # Run PHP-CS-Fixer
make rector # Run Rector
make install # Composer install
make update # Composer update
make cache-clear # Clear Composer cache
make up # Start containers only
make down # Stop containers
make build # Build Docker images
All PHP commands run inside the lexik_translation Docker container, so you don’t need PHP or extensions installed on the host.
If make is not installed (typical on Windows), you can run the same steps using Docker Compose directly.
Start services and install dependencies
docker compose up -d
docker compose run --rm lexik_translation composer install --prefer-dist --no-progress
Run tests
docker compose run --rm lexik_translation composer test
Run PHPStan
docker compose run --rm lexik_translation vendor/bin/phpstan analyse --memory-limit=512M
Run PHP-CS-Fixer
docker compose run --rm lexik_translation vendor/bin/php-cs-fixer fix --config=.php-cs-fixer.dist.php
Run Rector
docker compose run --rm lexik_translation vendor/bin/rector process
Other commands
docker compose run --rm lexik_translation composer install --prefer-dist --no-progressdocker compose run --rm lexik_translation composer update --no-progressdocker compose run --rm lexik_translation composer clear-cacheOn Windows you can also install Make (e.g. via Chocolatey (choco install make), Scoop, or WSL) and use the Makefile as on Linux/macOS.
The following cache/result files are not committed (they are in .gitignore):
.php-cs-fixer.cache — PHP-CS-Fixer cache.phpunit.result.cache — PHPUnit result cacheYou can delete them locally at any time; they will be recreated when you run the tools again.
How can I help you explore Laravel packages today?