Implemented the usage of the system PHP interpreter #1098
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The full new feature is implemented in the first commit and then partially reverted to the deprecation mode in the second one.
Migration path:
use
andswitch
commands will not have the intended PHP version constraints whilesystem
andsystem-off
will. This will motivate the users to configure their environment as expected.TODO:
PHPBREW_SYSTEM_PHP
has been introduced. If set, it must contain the full path to the system PHP interpreter, e.g./usr/bin/php
.__phpbrew_php_exec()
is now the key entry point from the shell PHPBrew wrapper to the PHP implementation. It uses the system PHP interpreter if it's set or falls back to the current one. Also it tries to usebin/phpbrew
if we're currently in the PHPBrew source directory.env
subcommand implementations have been removed from the shell whappers since the subcommand can be properly handled by a PHP implementation.Behavior tested manually on Fish and Bash:
Closes #872.