Skip to content

Commit

Permalink
All commands now return status.
Browse files Browse the repository at this point in the history
  • Loading branch information
bbankowski committed Nov 29, 2019
1 parent a683ba2 commit fae0e25
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bin/ControllerGeneratorCommand.php
Expand Up @@ -36,6 +36,8 @@ public function execute(InputInterface $input, OutputInterface $output)
$this->input = $input;
$this->output = $output;
$this->generate();

return 0;
}

private function generate()
Expand Down
2 changes: 2 additions & 0 deletions bin/MigrationDumperCommand.php
Expand Up @@ -36,5 +36,7 @@ public function execute(InputInterface $input, OutputInterface $output)
$dumper = new MigrationDumper($output, $dbConfig, new MigrationCommandExecutor());
$dumper->dumpSchema($schemaFile);
$dumper->dumpData($dataFile);

return 0;
}
}
2 changes: 2 additions & 0 deletions bin/MigrationGeneratorCommand.php
Expand Up @@ -68,5 +68,7 @@ public function run(Db \$db)
file_put_contents($path, $data);

$this->output->writeln("<comment>Generating...</comment> <info>DONE</info>");

return 0;
}
}
2 changes: 2 additions & 0 deletions bin/MigrationSqlImporterCommand.php
Expand Up @@ -33,5 +33,7 @@ public function execute(InputInterface $input, OutputInterface $output)

$importer = new MigrationImporter($output, $dbConfig, new MigrationCommandExecutor());
$importer->importAll($files);

return 0;
}
}
2 changes: 2 additions & 0 deletions bin/ModelGeneratorCommand.php
Expand Up @@ -45,6 +45,8 @@ public function execute(InputInterface $input, OutputInterface $output)
$this->input = $input;
$this->output = $output;
$this->generateModel();

return 0;
}

public function fail($message, $exitCode = 1)
Expand Down
2 changes: 2 additions & 0 deletions bin/RoutesCommand.php
Expand Up @@ -60,6 +60,8 @@ public function execute(InputInterface $input, OutputInterface $output)
$this->all();
}
}

return 0;
}

private function runSelectedGenerators($selectedGeneratedOptions, $generateOptionFunctionMap)
Expand Down

0 comments on commit fae0e25

Please sign in to comment.