Use phpmnd to detect magic numbers

This commit is contained in:
Pierre Rudloff 2022-01-27 00:03:37 +01:00
parent 5ed15afe1f
commit 835170f4b5
3 changed files with 162 additions and 1 deletions

View file

@ -51,6 +51,7 @@
"phpro/grumphp": "^1.3",
"phpstan/phpstan": "^0.12.72",
"phpunit/phpunit": "^9.5",
"povils/phpmnd": "^2.5",
"smarty-gettext/smarty-gettext": "^1.6",
"squizlabs/php_codesniffer": "^3.5",
"symfony/error-handler": "^5.4",

161
composer.lock generated
View file

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "5279862ad00f33cc3bf02760fa6b336b",
"content-hash": "8ef5b9e86d63584d9a5838de62251f23",
"packages": [
{
"name": "aura/session",
@ -5691,6 +5691,108 @@
},
"time": "2018-03-27T07:00:25+00:00"
},
{
"name": "php-parallel-lint/php-console-color",
"version": "v0.3",
"source": {
"type": "git",
"url": "https://github.com/php-parallel-lint/PHP-Console-Color.git",
"reference": "b6af326b2088f1ad3b264696c9fd590ec395b49e"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/php-parallel-lint/PHP-Console-Color/zipball/b6af326b2088f1ad3b264696c9fd590ec395b49e",
"reference": "b6af326b2088f1ad3b264696c9fd590ec395b49e",
"shasum": ""
},
"require": {
"php": ">=5.4.0"
},
"replace": {
"jakub-onderka/php-console-color": "*"
},
"require-dev": {
"php-parallel-lint/php-code-style": "1.0",
"php-parallel-lint/php-parallel-lint": "1.0",
"php-parallel-lint/php-var-dump-check": "0.*",
"phpunit/phpunit": "~4.3",
"squizlabs/php_codesniffer": "1.*"
},
"type": "library",
"autoload": {
"psr-4": {
"JakubOnderka\\PhpConsoleColor\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"BSD-2-Clause"
],
"authors": [
{
"name": "Jakub Onderka",
"email": "jakub.onderka@gmail.com"
}
],
"support": {
"issues": "https://github.com/php-parallel-lint/PHP-Console-Color/issues",
"source": "https://github.com/php-parallel-lint/PHP-Console-Color/tree/master"
},
"time": "2020-05-14T05:47:14+00:00"
},
{
"name": "php-parallel-lint/php-console-highlighter",
"version": "v0.5",
"source": {
"type": "git",
"url": "https://github.com/php-parallel-lint/PHP-Console-Highlighter.git",
"reference": "21bf002f077b177f056d8cb455c5ed573adfdbb8"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/php-parallel-lint/PHP-Console-Highlighter/zipball/21bf002f077b177f056d8cb455c5ed573adfdbb8",
"reference": "21bf002f077b177f056d8cb455c5ed573adfdbb8",
"shasum": ""
},
"require": {
"ext-tokenizer": "*",
"php": ">=5.4.0",
"php-parallel-lint/php-console-color": "~0.2"
},
"replace": {
"jakub-onderka/php-console-highlighter": "*"
},
"require-dev": {
"php-parallel-lint/php-code-style": "~1.0",
"php-parallel-lint/php-parallel-lint": "~1.0",
"php-parallel-lint/php-var-dump-check": "~0.1",
"phpunit/phpunit": "~4.0",
"squizlabs/php_codesniffer": "~1.5"
},
"type": "library",
"autoload": {
"psr-4": {
"JakubOnderka\\PhpConsoleHighlighter\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Jakub Onderka",
"email": "acci@acci.cz",
"homepage": "http://www.acci.cz/"
}
],
"description": "Highlight PHP code in terminal",
"support": {
"issues": "https://github.com/php-parallel-lint/PHP-Console-Highlighter/issues",
"source": "https://github.com/php-parallel-lint/PHP-Console-Highlighter/tree/master"
},
"time": "2020-05-13T07:37:49+00:00"
},
{
"name": "phpdocumentor/reflection-common",
"version": "2.2.0",
@ -6513,6 +6615,63 @@
],
"time": "2021-09-25T07:38:51+00:00"
},
{
"name": "povils/phpmnd",
"version": "v2.5.0",
"source": {
"type": "git",
"url": "https://github.com/povils/phpmnd.git",
"reference": "574a071e608c86f871592023a91554c68df421a5"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/povils/phpmnd/zipball/574a071e608c86f871592023a91554c68df421a5",
"reference": "574a071e608c86f871592023a91554c68df421a5",
"shasum": ""
},
"require": {
"nikic/php-parser": "^4.0",
"php": "^7.1|^8.0",
"php-parallel-lint/php-console-highlighter": "^0.5",
"phpunit/php-timer": "^2.0||^3.0||^4.0||^5.0",
"symfony/console": "^4.0||^5.0",
"symfony/finder": "^4.0||^5.0"
},
"require-dev": {
"phpunit/phpunit": "^7.0||^8.0||^9.0",
"squizlabs/php_codesniffer": "^2.8.1||^3.5"
},
"bin": [
"bin/phpmnd"
],
"type": "application",
"extra": {
"branch-alias": {
"dev-master": "2.5-dev"
}
},
"autoload": {
"psr-4": {
"Povils\\PHPMND\\": "src/"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Povilas Susinskas",
"email": "povilassusinskas@gmail.com"
}
],
"description": "A tool to detect Magic numbers in codebase",
"support": {
"issues": "https://github.com/povils/phpmnd/issues",
"source": "https://github.com/povils/phpmnd/tree/v2.5.0"
},
"time": "2021-12-12T21:28:55+00:00"
},
{
"name": "psr/event-dispatcher",
"version": "1.0.0",

View file

@ -13,6 +13,7 @@ grumphp:
securitychecker_enlightn: ~
composer_normalize: ~
composer_dangling_locked_deps: ~
phpmnd: ~
phpcs:
standard: PSR12
phpstan: