mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2025-12-27 12:51:26 +08:00
- Changed migration command from `yarn run migrations:generate` to `yarn run db:migrations:generate` for consistency across the project. - Updated related documentation in `CLAUDE.md`, `migrations/README.md`, and `src/main/data/README.md` to reflect the new command. - Added a notice in `migrations/README.md` regarding potential database structure changes before the alpha release.
11 lines
783 B
Markdown
11 lines
783 B
Markdown
**THIS DIRECTORY IS NOT FOR RUNTIME USE**
|
|
|
|
**v2 Data Refactoring Notice**
|
|
Before the official release of the alpha version, the database structure may change at any time. To maintain simplicity, the database migration files will be periodically reinitialized, which may cause the application to fail. If this occurs, please delete the `cherrystudio.sqlite` file located in the user data directory.
|
|
|
|
- Using `libsql` as the `sqlite3` driver, and `drizzle` as the ORM and database migration tool
|
|
- Table schemas are defined in `src\main\data\db\schemas`
|
|
- `migrations/sqlite-drizzle` contains auto-generated migration data. Please **DO NOT** modify it.
|
|
- If table structure changes, we should run migrations.
|
|
- To generate migrations, use the command `yarn run db:migrations:generate`
|