nbgrp/auditor

GitHub: nbgrp/auditor

一个 Docker 化的 PHP 代码质量分析工具箱,基于 GrumPHP 并行运行多种静态分析和风格检查工具。

Stars: 4 | Forks: 1

# 审计员 [![Docker 拉取次数](https://img.shields.io/docker/pulls/nbgrp/auditor)](https://img.shields.io/docker/pulls/nbgrp/auditor) Auditor 是一个基于出色的 [GrumPHP](https://github.com/phpro/grumphp) 实用工具的工具箱, 它允许并行运行多个代码质量工具。 目前,Auditor 支持以下代码质量工具: - [Deptrac](https://github.com/qossmic/deptrac) - [Phan](https://github.com/phan/phan) - [PHP CS Fixer](https://github.com/FriendsOfPHP/PHP-CS-Fixer) - [PHP_CodeSniffer](https://github.com/squizlabs/PHP_CodeSniffer) - [PHP Mess Detector](https://github.com/phpmd/phpmd) - [PHP Magic Number Detector](https://github.com/povils/phpmnd) - [PHPStan](https://github.com/phpstan/phpstan) - [Psalm](https://github.com/vimeo/psalm) ## 用法 要使用 Auditor 工具容器,只需在包含 你的 `grumphp.yml` 的目录中运行以下命令: ``` docker run -it --rm -v $PWD:/app --workdir /app nbgrp/auditor:latest ``` 它会将你当前的工作目录 (`$PWD`) 传递到 Auditor 的容器中,并 为该目录中的所有文件执行 `grumphp run`,同时应用 `grumphp.yml` 中的设置。 当在 GitHub Actions 中使用 Auditor 时,你可能需要指定仓库内(包含 `grumphp.yml`)的工作目录。为此,你可以使用 `with.working_dir` 步骤 参数: ``` - name: Audit uses: docker://nbgrp/auditor:latest with: working_dir: inner_directory_with_grumphp_config ```
标签:Deptrac, Docker, GitHub Actions, GrumPHP, NIDS, OpenVAS, Phan, PHP, PHP_CodeSniffer, PHP-CS-Fixer, PHPMD, PHPStan, Psalm, SOC Prime, 代码分析, 代码规范, 凭证管理, 安全防御评估, 容器化, 开发工具, 自动笔记, 请求拦截, 错误基检测, 静态代码分析