diff --git a/composer.json b/composer.json index 0d9ed78f..a5140022 100644 --- a/composer.json +++ b/composer.json @@ -36,7 +36,7 @@ "phpunit/phpunit": "^8.5.21", "psalm/plugin-phpunit": "~0.16.1", "symfony/filesystem": "^5.4.0", - "vimeo/psalm": "^4.13.1" + "vimeo/psalm": "^4.14.0" }, "minimum-stability": "dev", "prefer-stable": true, diff --git a/composer.lock b/composer.lock index 2a6cec7e..28ebc406 100644 --- a/composer.lock +++ b/composer.lock @@ -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": "8759c424600b3e8a97864608dc160472", + "content-hash": "5a6d1e039b8d601fe9ae74a55d1abecd", "packages": [ { "name": "ergebnis/json-normalizer", @@ -1920,16 +1920,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.13.1", + "version": "v4.13.2", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "63a79e8daa781cac14e5195e63ed8ae231dd10fd" + "reference": "210577fe3cf7badcc5814d99455df46564f3c077" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/63a79e8daa781cac14e5195e63ed8ae231dd10fd", - "reference": "63a79e8daa781cac14e5195e63ed8ae231dd10fd", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/210577fe3cf7badcc5814d99455df46564f3c077", + "reference": "210577fe3cf7badcc5814d99455df46564f3c077", "shasum": "" }, "require": { @@ -1970,9 +1970,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.13.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.13.2" }, - "time": "2021-11-03T20:52:16+00:00" + "time": "2021-11-30T19:35:32+00:00" }, { "name": "openlss/lib-array2xml", @@ -5462,16 +5462,16 @@ }, { "name": "vimeo/psalm", - "version": "4.13.1", + "version": "v4.14.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "5cf660f63b548ccd4a56f62d916ee4d6028e01a3" + "reference": "14dcbc908ab2625cd7a74258ee6c740cbecc6140" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/5cf660f63b548ccd4a56f62d916ee4d6028e01a3", - "reference": "5cf660f63b548ccd4a56f62d916ee4d6028e01a3", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/14dcbc908ab2625cd7a74258ee6c740cbecc6140", + "reference": "14dcbc908ab2625cd7a74258ee6c740cbecc6140", "shasum": "" }, "require": { @@ -5562,9 +5562,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/4.13.1" + "source": "https://github.com/vimeo/psalm/tree/v4.14.0" }, - "time": "2021-11-23T23:52:49+00:00" + "time": "2021-12-04T17:49:24+00:00" }, { "name": "webmozart/assert", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index a988b628..3ef009e8 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,5 +1,5 @@ - + $differ @@ -7,7 +7,7 @@ $formatter $normalizer - + $composer->getPackage()->getExtra() $composerFile $composerFile @@ -18,45 +18,27 @@ $composerFile $composerFile $diff + $formatted->encoded() - + $composer $composerFile $diff $formatted - $locker $normalized - + createComposer diff encoded encoded + encoded format getExtra getLocker getPackage - isFresh - isLocked - isLocked normalize - - $composerFile - $composerFile - $composerFile - $composerFile - $composerFile - $composerFile - $composerFile - $composerFile - - - $composerFile - $composerFile - $composerFile - $composerFile - diff --git a/src/Command/NormalizeCommand.php b/src/Command/NormalizeCommand.php index 57bdbfbe..2acd8dae 100644 --- a/src/Command/NormalizeCommand.php +++ b/src/Command/NormalizeCommand.php @@ -272,7 +272,10 @@ protected function execute( return 1; } - \file_put_contents($composerFile, $formatted); + \file_put_contents( + $composerFile, + $formatted->encoded() + ); $io->write(\sprintf( 'Successfully normalized %s.',