2019-06-23 02:30:24 +02:00
|
|
|
## Development
|
2019-03-10 20:29:25 +01:00
|
|
|
|
2019-07-02 21:44:13 +02:00
|
|
|
### Quickstart
|
|
|
|
|
2019-06-23 18:16:09 +02:00
|
|
|
- `npm install`, the postinstall runs
|
|
|
|
- `npm run rebuild`
|
|
|
|
- might need to install some build tools depending on your platform
|
|
|
|
- `npm run typeorm:migrate` for installing the database
|
2019-06-16 21:41:04 +02:00
|
|
|
- `npm run tsc` for backend
|
|
|
|
- `npm run webpack` for frontend
|
2019-07-02 21:44:13 +02:00
|
|
|
- `npm run dev`
|
|
|
|
|
|
|
|
### Git Commits
|
|
|
|
|
|
|
|
This project uses [Conventional Commits](https://www.conventionalcommits.or) with the following types:
|
|
|
|
- `feat`: features, if any part of your commit implements a new function, use this
|
|
|
|
- `fix`: bugfixes
|
|
|
|
- `doc`: documentation
|
|
|
|
- `refactor`: code refactoring
|
2019-07-02 21:54:38 +02:00
|
|
|
- `config`: changing configuration (linter, build process)
|
2019-07-02 22:17:00 +02:00
|
|
|
- `update`: updating dependencies and associated changes
|
2019-07-02 21:44:13 +02:00
|
|
|
|
|
|
|
Always try to split up your changes into coherent commits, a single commit should do a single thing.
|
2019-06-23 02:30:24 +02:00
|
|
|
|
2019-06-23 03:33:48 +02:00
|
|
|
### Database Migrations
|
|
|
|
|
|
|
|
Migrations are stored in [src/main/migrations](src/main/migrations) and handled by typeorm.
|
|
|
|
|
|
|
|
To auto-generate a migration:
|
2019-06-23 15:35:57 +02:00
|
|
|
`node_modules/.bin/typeorm migration:generate -n <migration name> -c <connection name>`
|
2019-06-23 03:33:48 +02:00
|
|
|
|
|
|
|
To create an empty creation which can be filled with custom migration code:
|
2019-06-23 15:35:57 +02:00
|
|
|
`node_modules/.bin/typeorm migration:create -n <migration name> -c <connection name>`
|
2019-06-23 03:33:48 +02:00
|
|
|
|
|
|
|
To run migrations:
|
|
|
|
`node_modules/.bin/typeorm migration:run -c <connection name>`
|
|
|
|
This is also pre-defined in the npm script `typeorm:migrate`.
|