Skip to content

Commit 5d25537

Browse files
committed
Update README
1 parent 30d5a9b commit 5d25537

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -191,21 +191,23 @@ ref likes_liked_by_id_users_id_fk: likes.liked_by_id > users.id [delete: no acti
191191
| Option | Type | Description |
192192
| ---------- | -------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
193193
| schema | PgSchema | An object containing Postgres dialect tables, enums and relations |
194-
| out | string | The output directory and file name. Uses the current working directory as the root |
194+
| out? | string | The output directory and file name. Uses the current working directory as the root. If not set, it will not write the DBML file. |
195195
| relational | boolean? | If set to true, it will create references based on the relations generated with the `relations` function instead of foreign keys. Useful for databases that don't support foreign keys. Default: `false`. |
196196

197197
**mysqlGenerate**
198198

199199
| Option | Type | Description |
200200
| ---------- | ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
201201
| schema | MySqlSchema | An object containing MySQL dialect tables and relations |
202-
| out | string | The output directory and file name. Uses the current working directory as the root |
202+
| out? | string | The output directory and file name. Uses the current working directory as the root. If not set, it will not write the DBML file. |
203203
| relational | boolean? | If set to true, it will create references based on the relations generated with the `relations` function instead of foreign keys. Useful for databases that don't support foreign keys. Default: `false`. |
204204

205205
**sqliteGenerate**
206206

207207
| Option | Type | Description |
208208
| ---------- | ------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
209209
| schema | SQLiteSchema | An object containing SQLite dialect tables and relations |
210-
| out | string | The output directory and file name. Uses the current working directory as the root |
210+
| out? | string | The output directory and file name. Uses the current working directory as the root. If not set, it will not write the DBML file. |
211211
| relational | boolean? | If set to true, it will create references based on the relations generated with the `relations` function instead of foreign keys. Useful for databases that don't support foreign keys. Default: `false`. |
212+
213+
All generate functions return the DBML as a string regardless if a file is written or not, in case you want to do something with the generated DBML.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "drizzle-dbml-generator",
3-
"version": "0.5.0",
3+
"version": "0.6.0",
44
"description": "Convert your Drizzle ORM schema into DBML markup",
55
"main": "dist/index.cjs",
66
"module": "dist/index.js",

0 commit comments

Comments
 (0)