mirror of
https://github.com/laravel/valet.git
synced 2026-02-05 08:30:07 +01:00
Remove '/Users/' prefix
This commit is contained in:
@@ -3,7 +3,7 @@
|
|||||||
/**
|
/**
|
||||||
* Define the user's "~/.valet" path.
|
* Define the user's "~/.valet" path.
|
||||||
*/
|
*/
|
||||||
define('VALET_HOME_PATH', '/Users/'.posix_getpwuid(fileowner(__FILE__))['name'].'/.valet');
|
define('VALET_HOME_PATH', posix_getpwuid(fileowner(__FILE__))['dir'].'/.valet');
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* De-escalate root privileges down to Valet directory owner.
|
* De-escalate root privileges down to Valet directory owner.
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ protected static function download($output)
|
|||||||
*/
|
*/
|
||||||
protected static function createCustomConfigurationFile()
|
protected static function createCustomConfigurationFile()
|
||||||
{
|
{
|
||||||
$dnsMasqConfigPath = '/Users/'.$_SERVER['SUDO_USER'].'/.valet/dnsmasq.conf';
|
$dnsMasqConfigPath = $_SERVER['HOME'].'/.valet/dnsmasq.conf';
|
||||||
|
|
||||||
if (! file_exists('/usr/local/etc/dnsmasq.conf')) {
|
if (! file_exists('/usr/local/etc/dnsmasq.conf')) {
|
||||||
copy('/usr/local/opt/dnsmasq/dnsmasq.conf.example', '/usr/local/etc/dnsmasq.conf');
|
copy('/usr/local/opt/dnsmasq/dnsmasq.conf.example', '/usr/local/etc/dnsmasq.conf');
|
||||||
|
|||||||
Reference in New Issue
Block a user