mirror of
https://github.com/laravel/valet.git
synced 2026-02-05 00:20:08 +01:00
Run brew list as user
As brew no longer allows running itself as root, we need to run it at the current user. This resolves #221.
This commit is contained in:
@@ -30,7 +30,7 @@ function __construct(CommandLine $cli, Filesystem $files)
|
||||
*/
|
||||
function installed($formula)
|
||||
{
|
||||
return in_array($formula, explode(PHP_EOL, $this->cli->run('brew list | grep '.$formula)));
|
||||
return in_array($formula, explode(PHP_EOL, $this->cli->run('sudo -u '.user().' brew list | grep '.$formula)));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user