ohmyform-api/src/cli.ts
2020-05-08 22:40:14 +02:00

17 lines
346 B
TypeScript

import { BootstrapConsole } from 'nestjs-console';
import { AppModule } from './app.module';
const bootstrap = new BootstrapConsole({
module: AppModule,
useDecorators: true,
});
bootstrap.init().then(async (app) => {
try {
await app.init();
await bootstrap.boot();
process.exit(0);
} catch (e) {
process.exit(1);
}
});