0

I am calling multi command in this command class:

public function handle()
{
    foreach ($this->argument('step') as $step) {
        if (command_exists("private:{$step}")) {
            $this->call("private:{$step}");

            $this->info("{$step} is completed");
            $this->line("-----");
        }
    }
}

I need to Waiting for each response in loop

mohammad
  • 95
  • 7
  • I think you need to be a little bit more clear about what you want to do and what the problem is – Gert B. Aug 16 '21 at 11:51
  • This code already waiting for `$this->call("private:{$step}")` response - next step will not be started before this line return result. – Maksim Aug 16 '21 at 12:03
  • `$this->call("private:{$step}")` dosent waiting response – mohammad Aug 16 '21 at 12:10
  • @mohammad you could use [`$this->confirm("Are you sure you want to run private:{$step}?");`](https://laravel.com/docs/8.x/artisan#asking-for-confirmation), but I am not sure if it is available in Lumen. – matiaslauriti Aug 31 '21 at 09:12

0 Answers0