github carthage-software/mago 1.0.0-beta.22
Mago 1.0.0-beta.22

latest releases: 1.0.0-beta.24, 1.0.0-beta.23
7 hours ago

Mago 1.0.0-beta.22

Mago 1.0.0-beta.22 is a quality-of-life release focused on improving the analysis of common PHP patterns, especially in template files, and making the command-line interface more intuitive and powerful.

📄 Improved PHP Template Analysis

This release resolves two key issues that significantly improve the experience of analyzing files that mix PHP and HTML.

  • Echo Tag (<?=) Usage: Variables and expressions used inside short echo tags (<?= $var ?>) are now correctly recognized as "used," eliminating a common source of unused-statement false positives. (#479)
  • @var Before Closing Tag: @var docblocks placed immediately before a PHP closing tag (?>) are now correctly processed. This makes it much easier to properly type-hint variables that are available to the template scope. (#445)

✨ CLI & Linter Improvements

  • New --colors Flag: The old --no-color flag has been deprecated in favor of a more flexible --colors=[auto|always|never] option. This aligns with modern CLI tool conventions and allows you to force colorized output in CI environments with --colors=always. (#481)
  • Smarter Baseline Flags: Action flags like --generate-baseline and --verify-baseline now automatically use the baseline path from your mago.toml file. You no longer need to specify --baseline <path> on the command line every time. (#480)
  • no-noop Rule Fix & Auto-Fix: The no-noop rule has been corrected to avoid false positives on intentional empty statements (e.g., if(...);). Additionally, it now has a safe auto-fix to remove truly redundant semicolons when you run mago lint --fix.

Closed Issues


Full Changelog: 1.0.0-beta.21...1.0.0-beta.22

Don't miss a new mago release

NewReleases is sending notifications on new releases.