awesome-repositories.com
博客
awesome-repositories.com

通过 AI 驱动的搜索,发现最优秀的开源仓库。

探索精选搜索开源替代品自托管软件博客网站地图
项目关于排名机制媒体报道MCP 服务器
法律隐私政策服务条款
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
carthage-software avatar

carthage-software/mago

0
View on GitHub↗
2,867 星标·123 分支·Rust·apache-2.0·11 次浏览mago.carthage.software↗

Mago

Mago is a PHP static analysis tool, linter, and code formatter. It detects type errors, dead code, and logic bugs through advanced type inference and flow analysis, while providing a deterministic engine to rewrite source files according to style guides.

The project distinguishes itself with a WebAssembly runtime that enables PHP analysis to execute entirely within a web browser, allowing results to be shared via URL. It also provides a minimal Dockerized toolchain distributed as a scratch image for consistent execution across different processor architectures.

The toolset covers architecture rule enforcement to prevent structural decay, automated violation fixes, and static type analysis involving generics and conditional types. It includes a rule-based linter and utilities for abstract syntax tree traversal and visualization.

Installation is supported via a Composer wrapper, shell scripts, system package managers, or manual binary downloads, with cryptographic attestation verification to ensure release authenticity.

Features

  • Static Code Analysis - Provides advanced static analysis for PHP code to detect type errors, dead code, and logic bugs.
  • Code Formatting and Linting - Enforces consistent coding standards and automatically fixes stylistic violations in PHP source files.
  • Automated Lint Fixes - Automatically corrects detected lint violations in PHP source code to reduce manual cleanup effort.
  • Code Formatting Tools - Enforces consistent indentation, spacing, and brace placement through automated source code formatting.
  • Static Analysis Rules - Validates dependency rules and structural conventions defined in configuration to guard the project structure.
  • Deterministic Formatters - Provides a deterministic formatting engine that rewrites source files to a consistent style guide.
  • PHP Formatters - Provides a deterministic engine that rewrites PHP source files to follow standard style guides.
  • PHP Linters - Scans PHP code against configurable rules to identify coding standard violations and apply automatic fixes.
  • Browser-Based Runtimes - Executes PHP static analysis in the browser via WebAssembly and enables sharing results via URL.
  • Static Code Linting - Scans PHP source files against configurable rules to detect coding standard violations and potential bugs.
  • WebAssembly - Compiles the static analyzer to WebAssembly to enable serverless execution entirely within the browser.
  • Architecture Rule Enforcement - Validates project structure and dependency rules to prevent architectural decay in large PHP codebases.
  • Recursive AST Traversal - Implements recursive traversal of the abstract syntax tree to detect coding violations and apply automated fixes.
  • Static Analysis Engines - Detects bugs, dead code, and type mismatches by evaluating generics, conditional types, and flow narrowing.
  • Static Code Analysis Tools - Detects type errors, dead code, and logic bugs in PHP code using advanced type inference and flow analysis.
  • Containerized Toolchains - Provides a minimal Docker image that packages the static analysis, linting, and formatting toolset for consistent execution.
  • Docker Container Execution - Enables the execution of static analysis tools within minimal Docker containers across different architectures.
  • Toolchain Images - Ships a minimal 26 MB Docker image packaging static analysis, linting, and formatting for PHP projects.
  • Scratch-Based Images - Provides a minimal Docker image built from scratch for lightweight, multi-architecture deployment.
  • Scratch Docker Images - Distributes the toolchain as a minimal scratch-based Docker image for multi-architecture compatibility.
  • Browser-Based Runtimes - Runs PHP static analysis entirely in the web browser via WebAssembly to enable results sharing by URL.
  • Signals & Reactivity - Utilizes a signals-based reactive system to propagate changes and enable efficient incremental analysis updates.
  • Compile-Time Code Generation - Generates optimized PHP code and fixers during the build process to enhance runtime performance.
  • Linting Rule Configurations - Supports project-specific linting and formatting rules loaded from external configuration files.
  • Static Analysis - Improves developer experience through static analysis.

Star 历史

carthage-software/mago 的 Star 历史图表carthage-software/mago 的 Star 历史图表

AI 搜索

探索更多 awesome 仓库

用简单的语言描述您的需求 —— AI 将根据相关性为您从数千个精选开源项目中进行排序。

Start searching with AI

常见问题解答

carthage-software/mago 是做什么的?

Mago is a PHP static analysis tool, linter, and code formatter. It detects type errors, dead code, and logic bugs through advanced type inference and flow analysis, while providing a deterministic engine to rewrite source files according to style guides.

carthage-software/mago 的主要功能有哪些?

carthage-software/mago 的主要功能包括:Static Code Analysis, Code Formatting and Linting, Automated Lint Fixes, Code Formatting Tools, Static Analysis Rules, Deterministic Formatters, PHP Formatters, PHP Linters。

carthage-software/mago 有哪些开源替代品?

carthage-software/mago 的开源替代品包括: squizlabs/php_codesniffer — PHP_CodeSniffer is a static analysis tool, coding standard linter, and command-line validator for PHP. It scans files… wordpress/wordpress-coding-standards — WordPress Coding Standards is a collection of rules for the PHP CodeSniffer engine designed to enforce consistent… feross/standard — Standard is a zero-configuration static analyzer, linter, and formatter for JavaScript. It functions as a style guide… alibaba/p3c — p3c is a Java static analysis tool and code quality linter designed to enforce professional coding guidelines and… airbnb/ruby — This project provides a collection of coding standard specifications, style guides, and configuration assets used to… ansible/ansible-lint — ansible-lint is a static code analysis tool and linter designed to identify syntax errors and best practice violations…

Mago 的开源替代方案

相似的开源项目,按与 Mago 的功能重合度排序。
  • squizlabs/php_codesniffersquizlabs 的头像

    squizlabs/PHP_CodeSniffer

    10,771在 GitHub 上查看↗

    PHP_CodeSniffer is a static analysis tool, coding standard linter, and command-line validator for PHP. It scans files and directories to detect and report formatting errors and language-specific coding violations without executing the code. The project functions as an automated code formatter capable of correcting detected style and formatting violations to bring source code into compliance with defined standards. It uses token-based lexical analysis to match code patterns against rule sets, ensuring consistency across a codebase. The tool provides comprehensive capabilities for recursive fi

    PHPautomationclicoding-standards
    在 GitHub 上查看↗10,771
  • wordpress/wordpress-coding-standardsWordPress 的头像

    WordPress/WordPress-Coding-Standards

    2,757在 GitHub 上查看↗

    WordPress Coding Standards is a collection of rules for the PHP CodeSniffer engine designed to enforce consistent coding conventions and best practices within PHP projects. It functions as a specialized static analysis tool that scans source code to identify style violations, security vulnerabilities, and potential bugs before execution. By integrating into development workflows, it ensures that code adheres to official project conventions, maintaining readability and consistency across large-scale plugin and theme development. The project distinguishes itself through deep domain-specific val

    PHPcoding-conventionsphp-codesnifferphpcs
    在 GitHub 上查看↗2,757
  • feross/standardfeross 的头像

    feross/standard

    29,431在 GitHub 上查看↗

    Standard is a zero-configuration static analyzer, linter, and formatter for JavaScript. It functions as a style guide that enforces consistent coding rules and identifies programming errors without requiring manual configuration files. The tool distinguishes itself by providing an automatic code fixer that scans source files to correct style violations and ensure a uniform codebase. It implements a predefined rule set to eliminate the need for project-specific configuration. The project covers a broad range of static analysis capabilities, including support for experimental language syntax a

    JavaScript
    在 GitHub 上查看↗29,431
  • alibaba/p3calibaba 的头像

    alibaba/p3c

    30,827在 GitHub 上查看↗

    p3c is a Java static analysis tool and code quality linter designed to enforce professional coding guidelines and quality standards. It utilizes a set of custom rules based on the PMD engine to scan source code for style violations, performance bottlenecks, and potential bugs. The project is distributed as an IDE linting plugin that provides real-time feedback and warnings during development. It also includes functionality for pre-commit code quality gates, allowing modified files to be scanned and blocked if they violate defined rules before being committed to version control. The analysis

    Kotlin
    在 GitHub 上查看↗30,827
  • 查看 Mago 的所有 30 个替代方案→