From 60eb7cde090c043dbaaf8ae77bf82cddd026db8b Mon Sep 17 00:00:00 2001 From: lordofthebrain Date: Fri, 27 Jun 2025 10:48:19 +0200 Subject: [PATCH 1/2] don't run migrate-fresh silent by default --- src/Commands/MigrateFresh.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Commands/MigrateFresh.php b/src/Commands/MigrateFresh.php index b626c7750..1a12d51f5 100644 --- a/src/Commands/MigrateFresh.php +++ b/src/Commands/MigrateFresh.php @@ -46,7 +46,7 @@ public function handle() ])); $this->info('Migrating.'); - $this->callSilent('tenants:migrate', [ + $this->call('tenants:migrate', [ '--tenants' => [$tenant->getTenantKey()], '--step' => $this->option('step'), '--force' => true, From 53f18e80f54cf814f7a7fa2e455ded4d4b5bbb6b Mon Sep 17 00:00:00 2001 From: lordofthebrain Date: Mon, 30 Jun 2025 13:24:38 +0200 Subject: [PATCH 2/2] migrate fresh show output with verbose --- src/Commands/MigrateFresh.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/Commands/MigrateFresh.php b/src/Commands/MigrateFresh.php index 1a12d51f5..21c36cc3d 100644 --- a/src/Commands/MigrateFresh.php +++ b/src/Commands/MigrateFresh.php @@ -8,6 +8,7 @@ use Stancl\Tenancy\Concerns\DealsWithMigrations; use Stancl\Tenancy\Concerns\HasATenantsOption; use Symfony\Component\Console\Input\InputOption; +use Symfony\Component\Console\Output\NullOutput; final class MigrateFresh extends Command { @@ -46,11 +47,12 @@ public function handle() ])); $this->info('Migrating.'); - $this->call('tenants:migrate', [ + $output = $this->getOutput()->isVerbose() ? $this->output : new NullOutput; + $this->runCommand('tenants:migrate', [ '--tenants' => [$tenant->getTenantKey()], '--step' => $this->option('step'), '--force' => true, - ]); + ], $output); }); $this->info('Done.');