postio / apps /commands /src /main.ts
Leon4gr45's picture
Upload folder using huggingface_hub (part 4)
3722089 verified
Raw
History Blame Contribute Delete
506 Bytes
import { NestFactory } from '@nestjs/core';
import { CommandModule } from './command.module';
import { CommandService } from 'nestjs-command';
async function bootstrap() {
// some comment again
const app = await NestFactory.createApplicationContext(CommandModule, {
logger: ['error'],
});
try {
await app.select(CommandModule).get(CommandService).exec();
await app.close();
} catch (error) {
console.error(error);
await app.close();
process.exit(1);
}
}
bootstrap();