This release of Mago focuses on improving the developer experience (DX) with a new initialization command, enhanced configuration options, and bug fixes.
New Features
-
mago init
command: Effortlessly set up Mago for your project with the new interactivemago init
command! This command guides you through the essential configuration options, including source paths, external dependencies, PHP version, and framework plugins. It can even detect and use settings from yourcomposer.json
file. This makes getting started with Mago a breeze! ✨ -
Global options: We've added several new global options to give you more control over Mago's behavior:
--config
: Specify the path to yourmago.toml
configuration file.--php-version
: Override the PHP version used for parsing and analysis.--threads
: Control the number of threads used for linting and formatting.--allow-unsupported-php-version
: Allow the use of unsupported PHP versions (use with caution!).--workspace
: Define the workspace directory for your project. This also influences where Mago looks for the configuration file.
These options can be used with any Mago command and must be specified before the command (e.g.,
mago --workspace my-project lint
).
Bug Fixes
- Token Precedence: Fixed a bug in the
mago-token
crate where the precedence of[
was incorrectly set, causing issues with parsing certain expressions.
Other Changes
- Improved Test Coverage: Added more test cases for the formatter to ensure better code quality and prevent regressions.
This release makes Mago even more user-friendly and reliable. We hope you enjoy the new features and improvements!
Full Changelog: 0.14.0...0.15.0