Skip to content

Latest commit

 

History

History
64 lines (43 loc) · 711 Bytes

README.md

File metadata and controls

64 lines (43 loc) · 711 Bytes

codebench-api

The CodeBench main API.

Requirements

  • NodeJS v16+
  • PostgreSQL (cf docker-compose.yml)

Run API

Dev with hot-reloading:

npm run dev

Prod:

npm start

Manage database with TypeORM

Delete schema:

npm run db:drop

Run all migrations:

npm run db:migrate

Reset db (combination of drop and migrate)

npm run db:reset
npm run typeorm migration:generate -- -n xxx

Create migration:

# After editing or adding an Entity
npm run typeorm migration:generate -- -n AddNewEntity

Style

Available commands for eslint/prettier:

npm run lint:check
npm run lint:fix
npm run format:check
npm run format:fix