public function perform()
    {
        if (!$this->verifyConfigured() || !$this->verifyEnvironment()) {
            return;
        }

        $found = false;
        $count = $this->option('one') ? 1 : PHP_INT_MAX;

        while ($count > 0 && ($migration = $this->migrator->run())) {
            $found = true;
            $count--;

            $this->sprintf(
                "<info>Migration <comment>%s</comment> was successfully executed.</info>",
                $migration->getState()->getName()
            );
        }

        if (!$found) {
            $this->writeln("<fg=red>No outstanding migrations were found.</fg=red>");
        }
    }
public function perform()
    {
        if (!$this->verifyConfigured() || !$this->verifyEnvironment()) {
            return;
        }

        $found = false;
        $count = $this->option('one') ? 1 : PHP_INT_MAX;

        while ($count > 0 && ($migration = $this->migrator->run())) {
            $found = true;
            $count--;

            $this->sprintf(
                "<info>Migration <comment>%s</comment> was successfully executed.</info>",
                $migration->getState()->getName()
            );
        }

        if (!$found) {
            $this->writeln("<fg=red>No outstanding migrations were found.</fg=red>");
        }
    }
public function perform ( ) { if ( ! $ this -> verifyConfigured ( ) || ! $ this -> verifyEnvironment ( ) ) { return ; } $ found = false ; $ count = $ this -> option ( 'one' ) ? 1 : PHP_INT_MAX ; while ( $ count > 0 && ( $ migration = $ this -> migrator -> run ( ) ) ) { $ found = true ; $ count -- ; $ this -> sprintf ( "<info>Migration <comment>%s</comment> was successfully executed.</info>" , $ migration -> getState ( ) -> getName ( ) ) ; } if ( ! $ found ) { $ this -> writeln ( "<fg=red>No outstanding migrations were found.</fg=red>" ) ; } }
Execute one or multiple migrations.
Execute one or multiple migrations .