1
0
mirror of https://github.com/laravel/valet.git synced 2026-02-06 16:50:09 +01:00

Change default PHP install pkg to 'php'

When no homebrew-installed PHP version is found, Valet attempts to install one.
The old default was `php71`. This PR changes it to `php`, which will install the latest Homebrew PHP version.
The problem with installing an older version is that Homebrew no longer symlinks it automatically. Rewriting Valet to do the symlinking is a little more involved since we should check for "which" version to link, vs other versions installed, etc.
Simply changing the default to the primary supported PHP version allows Valet to rely on Homebrew symlinking it properly.
This commit is contained in:
Chris Brown
2019-01-07 21:35:15 -05:00
committed by Matt Stauffer
parent 67546f1fc3
commit 7dd06db2b0

View File

@@ -37,7 +37,7 @@ function __construct(Brew $brew, CommandLine $cli, Filesystem $files)
function install() function install()
{ {
if (! $this->brew->hasInstalledPhp()) { if (! $this->brew->hasInstalledPhp()) {
$this->brew->ensureInstalled('php71', [], $this->taps); $this->brew->ensureInstalled('php', [], $this->taps);
} }
$this->files->ensureDirExists('/usr/local/var/log', user()); $this->files->ensureDirExists('/usr/local/var/log', user());