PreflightVerify
class PreflightVerify (View source)
Helper methods to verify preflight state.
Methods
Throw an exception if the environment is not right for running Drush.
Fail fast if the php version does not meet the minimum requirements.
Evaluate the environment before command bootstrapping begins. If the php environment is too restrictive, then notify the user that a setting change is needed and abort.
Determine whether an ini value is valid based on the criteria.
Returns a localizable message about php.ini that varies depending on whether the php_ini_loaded_file() is available or not.
Details
void
verify(Environment $environment)
Throw an exception if the environment is not right for running Drush.
void
confirmPhpVersion(string|null $minimumPhpVersion)
Fail fast if the php version does not meet the minimum requirements.
protected void
confirmUsingCLI(Environment $environment)
Fail if not being run from the command line.
protected void
checkPhpIni()
Evaluate the environment before command bootstrapping begins. If the php environment is too restrictive, then notify the user that a setting change is needed and abort.
protected bool
invalidIniValue(mixed $ini_value, string|array $disallowed_value)
Determine whether an ini value is valid based on the criteria.
protected string
loadedPhpIniMessage()
Returns a localizable message about php.ini that varies depending on whether the php_ini_loaded_file() is available or not.