20 lines
444 B
TypeScript
20 lines
444 B
TypeScript
import { Cli } from './cli.ts';
|
|
|
|
class GameCI {
|
|
public static async run() {
|
|
try {
|
|
const { command, options } = await new Cli().validateAndParseArguments();
|
|
|
|
const success = await command.execute(options);
|
|
|
|
if (!success) log.warning(`${command.constructor.name} failed.`);
|
|
} catch (error) {
|
|
// eslint-disable-next-line no-console
|
|
console.error(error);
|
|
Deno.exit(1);
|
|
}
|
|
}
|
|
}
|
|
|
|
await GameCI.run();
|