Updated PHPStan

This commit is contained in:
Dylan K. Taylor 2024-01-08 16:20:42 +00:00
parent ee977c8001
commit 4db38ee452
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D
3 changed files with 18 additions and 8 deletions

View File

@ -32,6 +32,7 @@ use function getcwd;
use function getopt; use function getopt;
use function implode; use function implode;
use function ini_get; use function ini_get;
use function is_string;
use function microtime; use function microtime;
use function preg_quote; use function preg_quote;
use function realpath; use function realpath;
@ -147,8 +148,17 @@ function main() : void{
}else{ }else{
$build = 0; $build = 0;
} }
if(isset($opts["out"])){
if(!is_string($opts["out"])){
echo "--out cannot be specified multiple times" . PHP_EOL;
exit(1);
}
$pharPath = $opts["out"];
}else{
$pharPath = getcwd() . DIRECTORY_SEPARATOR . "PocketMine-MP.phar";
}
foreach(buildPhar( foreach(buildPhar(
$opts["out"] ?? getcwd() . DIRECTORY_SEPARATOR . "PocketMine-MP.phar", $pharPath,
dirname(__DIR__) . DIRECTORY_SEPARATOR, dirname(__DIR__) . DIRECTORY_SEPARATOR,
[ [
'resources', 'resources',

View File

@ -52,7 +52,7 @@
"symfony/filesystem": "~6.4.0" "symfony/filesystem": "~6.4.0"
}, },
"require-dev": { "require-dev": {
"phpstan/phpstan": "1.10.50", "phpstan/phpstan": "1.10.55",
"phpstan/phpstan-phpunit": "^1.1.0", "phpstan/phpstan-phpunit": "^1.1.0",
"phpstan/phpstan-strict-rules": "^1.2.0", "phpstan/phpstan-strict-rules": "^1.2.0",
"phpunit/phpunit": "~10.3.0 || ~10.2.0 || ~10.1.0" "phpunit/phpunit": "~10.3.0 || ~10.2.0 || ~10.1.0"

12
composer.lock generated
View File

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically" "This file is @generated automatically"
], ],
"content-hash": "894648a63ed7cd84303937208d1684af", "content-hash": "d7a3fceea557add1b8cb461554db1ee7",
"packages": [ "packages": [
{ {
"name": "adhocore/json-comment", "name": "adhocore/json-comment",
@ -1380,16 +1380,16 @@
}, },
{ {
"name": "phpstan/phpstan", "name": "phpstan/phpstan",
"version": "1.10.50", "version": "1.10.55",
"source": { "source": {
"type": "git", "type": "git",
"url": "https://github.com/phpstan/phpstan.git", "url": "https://github.com/phpstan/phpstan.git",
"reference": "06a98513ac72c03e8366b5a0cb00750b487032e4" "reference": "9a88f9d18ddf4cf54c922fbeac16c4cb164c5949"
}, },
"dist": { "dist": {
"type": "zip", "type": "zip",
"url": "https://api.github.com/repos/phpstan/phpstan/zipball/06a98513ac72c03e8366b5a0cb00750b487032e4", "url": "https://api.github.com/repos/phpstan/phpstan/zipball/9a88f9d18ddf4cf54c922fbeac16c4cb164c5949",
"reference": "06a98513ac72c03e8366b5a0cb00750b487032e4", "reference": "9a88f9d18ddf4cf54c922fbeac16c4cb164c5949",
"shasum": "" "shasum": ""
}, },
"require": { "require": {
@ -1438,7 +1438,7 @@
"type": "tidelift" "type": "tidelift"
} }
], ],
"time": "2023-12-13T10:59:42+00:00" "time": "2024-01-08T12:32:40+00:00"
}, },
{ {
"name": "phpstan/phpstan-phpunit", "name": "phpstan/phpstan-phpunit",