← Back
Editing: BundledPhpExtensionRefusal.php
<?php declare(strict_types=1); namespace Php\Pie\DependencyResolver; use Php\Pie\Platform\TargetPhp\PhpBinaryPath; use RuntimeException; use function sprintf; use const PHP_EOL; class BundledPhpExtensionRefusal extends RuntimeException { public static function forPackage(Package $package): self { return new self(sprintf( 'Bundled PHP extension %s should be installed by your distribution, not by PIE.%s%sCombining installation methods of bundled PHP extensions can lead to confusing and unintended consequences.%s%sIf you are really sure, you want to install %s using PIE, re-run the command with the --force flag.', $package->name(), PHP_EOL, PHP_EOL, PHP_EOL, PHP_EOL, $package->name(), )); } public static function forPhpExtraVersion(PhpBinaryPath $phpBinaryPath): self { return new self(sprintf( 'Cannot install bundled PHP extension for non-stable versions of PHP (detected: %s)', $phpBinaryPath->phpVersionWithExtra(), )); } }
Save File
Cancel