drizzle-kit 0.20.14-c82ab68 → 0.20.14-d8f1e46
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin.cjs +7142 -7442
- package/cli/commands/migrate.d.ts +24 -24
- package/cli/commands/mysqlIntrospect.d.ts +8 -8
- package/cli/commands/mysqlPushUtils.d.ts +2 -2
- package/cli/commands/mysqlUp.d.ts +2 -2
- package/cli/commands/pgConnect.d.ts +1 -1
- package/cli/commands/pgIntrospect.d.ts +9 -12
- package/cli/commands/pgPushUtils.d.ts +2 -2
- package/cli/commands/pgUp.d.ts +2 -2
- package/cli/commands/sqliteIntrospect.d.ts +9 -9
- package/cli/commands/sqlitePushUtils.d.ts +3 -3
- package/cli/commands/sqliteUtils.d.ts +162 -0
- package/cli/commands/upFolders.d.ts +1 -1
- package/cli/commands/utils.d.ts +259 -14
- package/cli/validations/common.d.ts +7 -205
- package/cli/validations/mysql.d.ts +1 -6
- package/cli/validations/pg.d.ts +1 -6
- package/cli/views.d.ts +1 -1
- package/global.d.ts +1 -1
- package/index.d.mts +6 -8
- package/index.d.ts +6 -8
- package/index.js +0 -1
- package/introspect-mysql.d.ts +1 -1
- package/introspect-pg.d.ts +2 -5
- package/introspect-sqlite.d.ts +1 -1
- package/jsonStatements.d.ts +1 -1
- package/package.json +2 -3
- package/payload.d.mts +988 -18
- package/payload.d.ts +988 -18
- package/payload.js +1616 -13426
- package/payload.mjs +1538 -2213
- package/schemaValidator.d.ts +40 -40
- package/serializer/mysqlSchema.d.ts +616 -1854
- package/serializer/mysqlSerializer.d.ts +2 -2
- package/serializer/pgSchema.d.ts +684 -1009
- package/serializer/sqliteSchema.d.ts +570 -144
- package/serializer/sqliteSerializer.d.ts +2 -2
- package/snapshotsDiffer.d.ts +20 -24
- package/utils-studio.js +15 -390
- package/utils-studio.mjs +15 -389
- package/utils.d.ts +12 -12
- package/utils.js +735 -849
- package/utils.mjs +736 -849
- package/cli/validations/cli.d.ts +0 -104
- package/cli/validations/sqlite.d.ts +0 -382
package/index.d.mts
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
import { Dialect } from "./schemaValidator";
|
2
1
|
export type DbConnection = {
|
3
2
|
driver: "turso";
|
4
3
|
dbCredentials: {
|
@@ -46,14 +45,13 @@ export type DbConnection = {
|
|
46
45
|
};
|
47
46
|
};
|
48
47
|
export type Config = {
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
schemaFilter?: string | string[];
|
48
|
+
out?: string | undefined;
|
49
|
+
breakpoints?: boolean | undefined;
|
50
|
+
tablesFilter?: string | string[] | undefined;
|
51
|
+
schemaFilter?: string | string[] | undefined;
|
54
52
|
schema?: string | string[];
|
55
|
-
verbose?: boolean;
|
56
|
-
strict?: boolean;
|
53
|
+
verbose?: boolean | undefined;
|
54
|
+
strict?: boolean | undefined;
|
57
55
|
} & {
|
58
56
|
introspect?: {
|
59
57
|
casing: "camel" | "preserve";
|
package/index.d.ts
CHANGED
@@ -1,4 +1,3 @@
|
|
1
|
-
import { Dialect } from "./schemaValidator";
|
2
1
|
export type DbConnection = {
|
3
2
|
driver: "turso";
|
4
3
|
dbCredentials: {
|
@@ -46,14 +45,13 @@ export type DbConnection = {
|
|
46
45
|
};
|
47
46
|
};
|
48
47
|
export type Config = {
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
schemaFilter?: string | string[];
|
48
|
+
out?: string | undefined;
|
49
|
+
breakpoints?: boolean | undefined;
|
50
|
+
tablesFilter?: string | string[] | undefined;
|
51
|
+
schemaFilter?: string | string[] | undefined;
|
54
52
|
schema?: string | string[];
|
55
|
-
verbose?: boolean;
|
56
|
-
strict?: boolean;
|
53
|
+
verbose?: boolean | undefined;
|
54
|
+
strict?: boolean | undefined;
|
57
55
|
} & {
|
58
56
|
introspect?: {
|
59
57
|
casing: "camel" | "preserve";
|
package/index.js
CHANGED
package/introspect-mysql.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import "./@types/utils";
|
2
|
-
import
|
2
|
+
import { ConfigIntrospectCasing } from "./cli/commands/utils";
|
3
3
|
import { MySqlSchemaInternal } from "./serializer/mysqlSchema";
|
4
4
|
export declare const schemaToTypeScript: (schema: MySqlSchemaInternal, casing: ConfigIntrospectCasing["casing"]) => {
|
5
5
|
file: string;
|
package/introspect-pg.d.ts
CHANGED
@@ -1,12 +1,9 @@
|
|
1
1
|
import { AnyPgTable } from "drizzle-orm/pg-core";
|
2
2
|
import { Relation, Relations } from "drizzle-orm/relations";
|
3
3
|
import "./@types/utils";
|
4
|
-
import
|
4
|
+
import { ConfigIntrospectCasing } from "./cli/commands/utils";
|
5
5
|
import { PgSchemaInternal } from "./serializer/pgSchema";
|
6
|
-
export declare const
|
7
|
-
export declare const relationsToTypeScript: (schema: PgSchemaInternal, casing: ConfigIntrospectCasing) => {
|
8
|
-
file: string;
|
9
|
-
};
|
6
|
+
export declare const relationsToTypeScript: (schema: Record<string, Record<string, AnyPgTable<{}>>>, relations: Record<string, Relations<string, Record<string, Relation<string>>>>) => string;
|
10
7
|
export declare const schemaToTypeScript: (schema: PgSchemaInternal, casing: ConfigIntrospectCasing) => {
|
11
8
|
file: string;
|
12
9
|
imports: string;
|
package/introspect-sqlite.d.ts
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
import "./@types/utils";
|
2
|
-
import type { ConfigIntrospectCasing } from "./cli/
|
2
|
+
import type { ConfigIntrospectCasing } from "./cli/commands/utils";
|
3
3
|
import type { SQLiteSchemaInternal } from "./serializer/sqliteSchema";
|
4
4
|
export declare const indexName: (tableName: string, columns: string[]) => string;
|
5
5
|
export declare const schemaToTypeScript: (schema: SQLiteSchemaInternal, casing: ConfigIntrospectCasing["casing"]) => {
|
package/jsonStatements.d.ts
CHANGED
@@ -294,7 +294,7 @@ export interface JsonRenameSchema {
|
|
294
294
|
export type JsonAlterColumnStatement = JsonRenameColumnStatement | JsonAlterColumnTypeStatement | JsonAlterColumnSetDefaultStatement | JsonAlterColumnDropDefaultStatement | JsonAlterColumnSetNotNullStatement | JsonAlterColumnDropNotNullStatement | JsonAlterColumnDropOnUpdateStatement | JsonAlterColumnSetOnUpdateStatement | JsonAlterColumnDropAutoincrementStatement | JsonAlterColumnSetAutoincrementStatement | JsonAlterColumnSetPrimaryKeyStatement | JsonAlterColumnDropPrimaryKeyStatement;
|
295
295
|
export type JsonStatement = JsonAlterColumnStatement | JsonCreateTableStatement | JsonDropTableStatement | JsonRenameTableStatement | JsonCreateEnumStatement | JsonAddValueToEnumStatement | JsonDropColumnStatement | JsonAddColumnStatement | JsonCreateIndexStatement | JsonCreateReferenceStatement | JsonAlterReferenceStatement | JsonDeleteReferenceStatement | JsonDropIndexStatement | JsonReferenceStatement | JsonSqliteCreateTableStatement | JsonSqliteAddColumnStatement | JsonCreateCompositePK | JsonDeleteCompositePK | JsonAlterCompositePK | JsonCreateUniqueConstraint | JsonDeleteUniqueConstraint | JsonAlterUniqueConstraint | JsonCreateSchema | JsonDropSchema | JsonRenameSchema | JsonAlterTableSetSchema | JsonAlterTableRemoveFromSchema | JsonAlterTableSetNewSchema;
|
296
296
|
export declare const preparePgCreateTableJson: (table: Table, json2: PgSchema) => JsonCreateTableStatement;
|
297
|
-
export declare const prepareMySqlCreateTableJson: (table: Table, json2:
|
297
|
+
export declare const prepareMySqlCreateTableJson: (table: Table, json2: PgSchema) => JsonCreateTableStatement;
|
298
298
|
export declare const prepareSQLiteCreateTable: (table: Table) => JsonSqliteCreateTableStatement;
|
299
299
|
export declare const prepareDropTableJson: (table: Table) => JsonDropTableStatement;
|
300
300
|
export declare const prepareRenameTableJson: (tableFrom: Table, tableTo: Table) => JsonRenameTableStatement;
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "drizzle-kit",
|
3
|
-
"version": "0.20.14-
|
3
|
+
"version": "0.20.14-d8f1e46",
|
4
4
|
"repository": "https://github.com/drizzle-team/drizzle-kit-mirror",
|
5
5
|
"author": "Drizzle Team",
|
6
6
|
"license": "MIT",
|
@@ -68,7 +68,6 @@
|
|
68
68
|
"hanji": "^0.0.5",
|
69
69
|
"json-diff": "0.9.0",
|
70
70
|
"minimatch": "^7.4.3",
|
71
|
-
"pluralize": "^8.0.0",
|
72
71
|
"semver": "^7.5.4",
|
73
72
|
"zod": "^3.20.2"
|
74
73
|
},
|
@@ -81,7 +80,6 @@
|
|
81
80
|
"@types/minimatch": "^5.1.2",
|
82
81
|
"@types/node": "^18.11.15",
|
83
82
|
"@types/pg": "^8.10.7",
|
84
|
-
"@types/pluralize": "^0.0.33",
|
85
83
|
"@types/semver": "^7.5.5",
|
86
84
|
"@typescript-eslint/eslint-plugin": "^5.46.1",
|
87
85
|
"@typescript-eslint/parser": "^5.46.1",
|
@@ -100,6 +98,7 @@
|
|
100
98
|
"pg": "^8.11.3",
|
101
99
|
"postgres": "^3.3.5",
|
102
100
|
"prettier": "^2.8.1",
|
101
|
+
"tsup": "^8.0.2",
|
103
102
|
"tsx": "^3.12.1",
|
104
103
|
"typescript": "^4.9.4",
|
105
104
|
"uvu": "^0.5.6",
|