Skip to content

Commit

Permalink
fix(docs): Spelling of data-migrate command (#10003)
Browse files Browse the repository at this point in the history
  • Loading branch information
BlackHawkSigma authored Feb 13, 2024
1 parent fa2887c commit 6132ed5
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions docs/docs/cli-commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -149,37 +149,37 @@ yarn run v1.22.4
> [ { id: 1, email: '[email protected]', name: 'Tom' } ]
```
## dataMigrate
## data-migrate
Data migration tools.
```
yarn redwood dataMigrate <command>
```bash
yarn redwood data-migrate <command>
```
| Command | Description |
| :-------- | :------------------------------------------------------------------------------------------ |
| `install` | Appends `DataMigration` model to `schema.prisma`, creates `api/db/dataMigrations` directory |
| `up` | Executes outstanding data migrations |
### dataMigrate install
### data-migrate install
- Appends a `DataMigration` model to `schema.prisma` for tracking which data migrations have already run.
- Creates a DB migration using `yarn redwood prisma migrate dev --create-only create_data_migrations`.
- Creates `api/db/dataMigrations` directory to contain data migration scripts
```bash
yarn redwood dataMigrate install
yarn redwood data-migrate install
```
### dataMigrate up
### data-migrate up
Executes outstanding data migrations against the database. Compares the list of files in `api/db/dataMigrations` to the records in the `DataMigration` table in the database and executes any files not present.
If an error occurs during script execution, any remaining scripts are skipped and console output will let you know the error and how many subsequent scripts were skipped.
```bash
yarn redwood dataMigrate up
yarn redwood data-migrate up
```
## dev
Expand Down

0 comments on commit 6132ed5

Please sign in to comment.