mirror of
https://github.com/laravel/valet.git
synced 2026-02-05 08:30:07 +01:00
added which command for debugging
This commit is contained in:
15
valet.php
15
valet.php
@@ -92,6 +92,21 @@
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
* Determine which Valet driver the current directory is using.
|
||||
*/
|
||||
$app->command('which', function ($output) {
|
||||
require __DIR__.'/drivers/require.php';
|
||||
|
||||
$driver = ValetDriver::assign(getcwd(), basename(getcwd()), '/');
|
||||
|
||||
if ($driver) {
|
||||
$output->writeln('<info>This site is served by ['.get_class($driver).'].</info>');
|
||||
} else {
|
||||
$output->writeln('<fg=red>Valet could not determine which driver to use for this site.</>');
|
||||
}
|
||||
});
|
||||
|
||||
/**
|
||||
* Stream all of the logs for all sites.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user