drizzle-kit 0.20.17-9f0ea64 → 0.20.17-a1c0ab3
Sign up to get free protection for your applications and to get access to all the features.
- package/bin.cjs +71994 -35815
- package/index.d.mts +35 -65
- package/index.d.ts +35 -65
- package/package.json +8 -16
- package/payload.d.mts +1052 -18
- package/payload.d.ts +1052 -18
- package/payload.js +18757 -34176
- package/payload.mjs +17495 -32894
- package/utils-studio.js +1039 -3348
- package/utils-studio.mjs +1012 -3321
- package/utils.js +864 -223
- package/utils.mjs +839 -198
- package/@types/utils.d.ts +0 -12
- package/cli/commands/migrate.d.ts +0 -287
- package/cli/commands/mysqlIntrospect.d.ts +0 -55
- package/cli/commands/mysqlPushUtils.d.ts +0 -14
- package/cli/commands/pgIntrospect.d.ts +0 -59
- package/cli/commands/pgPushUtils.d.ts +0 -11
- package/cli/commands/sqliteIntrospect.d.ts +0 -104
- package/cli/commands/sqlitePushUtils.d.ts +0 -15
- package/cli/commands/utils.d.ts +0 -58
- package/cli/selector-ui.d.ts +0 -13
- package/cli/utils.d.ts +0 -13
- package/cli/validations/cli.d.ts +0 -169
- package/cli/validations/common.d.ts +0 -214
- package/cli/validations/mysql.d.ts +0 -35
- package/cli/validations/outputs.d.ts +0 -41
- package/cli/validations/pg.d.ts +0 -31
- package/cli/validations/sqlite.d.ts +0 -34
- package/cli/views.d.ts +0 -63
- package/global.d.ts +0 -6
- package/introspect-sqlite.d.ts +0 -10
- package/jsonDiffer.d.ts +0 -61
- package/jsonStatements.d.ts +0 -376
- package/migrationPreparator.d.ts +0 -35
- package/schemaValidator.d.ts +0 -1316
- package/serializer/index.d.ts +0 -9
- package/serializer/mysqlImports.d.ts +0 -7
- package/serializer/mysqlSchema.d.ts +0 -4650
- package/serializer/mysqlSerializer.d.ts +0 -7
- package/serializer/pgImports.d.ts +0 -11
- package/serializer/pgSchema.d.ts +0 -4792
- package/serializer/pgSerializer.d.ts +0 -7
- package/serializer/schemaToDrizzle.d.ts +0 -7
- package/serializer/sqliteImports.d.ts +0 -7
- package/serializer/sqliteSchema.d.ts +0 -2801
- package/serializer/sqliteSerializer.d.ts +0 -6
- package/snapshotsDiffer.d.ts +0 -3937
- package/sqlgenerator.d.ts +0 -33
- package/utils/words.d.ts +0 -7
- package/utils-studio.d.mts +0 -4
- package/utils-studio.d.ts +0 -4
- package/utils.d.ts +0 -72
package/sqlgenerator.d.ts
DELETED
@@ -1,33 +0,0 @@
|
|
1
|
-
import { JsonCreateIndexStatement, JsonDropIndexStatement, JsonDropTableStatement, JsonRenameTableStatement, JsonSqliteAddColumnStatement, JsonSqliteCreateTableStatement, JsonStatement } from "./jsonStatements";
|
2
|
-
import { Dialect } from "./schemaValidator";
|
3
|
-
export declare const pgNativeTypes: Set<string>;
|
4
|
-
declare abstract class Convertor {
|
5
|
-
abstract can(statement: JsonStatement, dialect: Dialect): boolean;
|
6
|
-
abstract convert(statement: JsonStatement): string;
|
7
|
-
}
|
8
|
-
export declare class SQLiteCreateTableConvertor extends Convertor {
|
9
|
-
can(statement: JsonStatement, dialect: Dialect): boolean;
|
10
|
-
convert(st: JsonSqliteCreateTableStatement): string;
|
11
|
-
}
|
12
|
-
export declare class SQLiteDropTableConvertor extends Convertor {
|
13
|
-
can(statement: JsonStatement, dialect: Dialect): boolean;
|
14
|
-
convert(statement: JsonDropTableStatement): string;
|
15
|
-
}
|
16
|
-
export declare class SqliteRenameTableConvertor extends Convertor {
|
17
|
-
can(statement: JsonStatement, dialect: Dialect): boolean;
|
18
|
-
convert(statement: JsonRenameTableStatement): string;
|
19
|
-
}
|
20
|
-
export declare class SQLiteAlterTableAddColumnConvertor extends Convertor {
|
21
|
-
can(statement: JsonStatement, dialect: Dialect): boolean;
|
22
|
-
convert(statement: JsonSqliteAddColumnStatement): string;
|
23
|
-
}
|
24
|
-
export declare class CreateSqliteIndexConvertor extends Convertor {
|
25
|
-
can(statement: JsonStatement, dialect: Dialect): boolean;
|
26
|
-
convert(statement: JsonCreateIndexStatement): string;
|
27
|
-
}
|
28
|
-
export declare class SqliteDropIndexConvertor extends Convertor {
|
29
|
-
can(statement: JsonStatement, dialect: Dialect): boolean;
|
30
|
-
convert(statement: JsonDropIndexStatement): string;
|
31
|
-
}
|
32
|
-
export declare const fromJson: (statements: JsonStatement[], dialect: Dialect) => string[];
|
33
|
-
export {};
|
package/utils/words.d.ts
DELETED
package/utils-studio.d.mts
DELETED
@@ -1,4 +0,0 @@
|
|
1
|
-
export { pgSchemaToDrizzle as drizzleSchemaPg } from "./serializer/schemaToDrizzle";
|
2
|
-
export { sqliteSchemaToDrizzle as drizzleSchemaSQLite } from "./serializer/schemaToDrizzle";
|
3
|
-
export { sqlitePushIntrospect } from "./cli/commands/sqliteIntrospect";
|
4
|
-
export { pgPushIntrospect } from "./cli/commands/pgIntrospect";
|
package/utils-studio.d.ts
DELETED
@@ -1,4 +0,0 @@
|
|
1
|
-
export { pgSchemaToDrizzle as drizzleSchemaPg } from "./serializer/schemaToDrizzle";
|
2
|
-
export { sqliteSchemaToDrizzle as drizzleSchemaSQLite } from "./serializer/schemaToDrizzle";
|
3
|
-
export { sqlitePushIntrospect } from "./cli/commands/sqliteIntrospect";
|
4
|
-
export { pgPushIntrospect } from "./cli/commands/pgIntrospect";
|
package/utils.d.ts
DELETED
@@ -1,72 +0,0 @@
|
|
1
|
-
import type { Dialect } from "./schemaValidator";
|
2
|
-
import type { NamedWithSchema } from "./cli/commands/migrate";
|
3
|
-
export type DB = {
|
4
|
-
query: <T extends any = any>(sql: string, params?: any[]) => Promise<T[]>;
|
5
|
-
};
|
6
|
-
export type SQLiteDB = {
|
7
|
-
query: <T extends any = any>(sql: string, params?: any[]) => Promise<T[]>;
|
8
|
-
run(query: string): Promise<void>;
|
9
|
-
};
|
10
|
-
export declare const copy: <T>(it: T) => T;
|
11
|
-
export declare const objectValues: <T extends object>(obj: T) => Array<T[keyof T]>;
|
12
|
-
export declare const assertV1OutFolder: (out: string) => void;
|
13
|
-
export type Journal = {
|
14
|
-
version: string;
|
15
|
-
dialect: Dialect;
|
16
|
-
entries: {
|
17
|
-
idx: number;
|
18
|
-
version: string;
|
19
|
-
when: number;
|
20
|
-
tag: string;
|
21
|
-
breakpoints: boolean;
|
22
|
-
}[];
|
23
|
-
};
|
24
|
-
export declare const dryJournal: (dialect: Dialect) => Journal;
|
25
|
-
export declare const prepareOutFolder: (out: string, dialect: Dialect) => {
|
26
|
-
meta: string;
|
27
|
-
snapshots: string[];
|
28
|
-
journal: any;
|
29
|
-
};
|
30
|
-
export declare const validateWithReport: (snapshots: string[], dialect: Dialect) => {
|
31
|
-
malformed: string[];
|
32
|
-
nonLatest: string[];
|
33
|
-
idsMap: Record<string, {
|
34
|
-
parent: string;
|
35
|
-
snapshots: string[];
|
36
|
-
}>;
|
37
|
-
rawMap: Record<string, any>;
|
38
|
-
};
|
39
|
-
export declare const prepareMigrationFolder: (outFolder: string | undefined, dialect: Dialect) => {
|
40
|
-
snapshots: string[];
|
41
|
-
journal: any;
|
42
|
-
};
|
43
|
-
export declare const prepareMigrationMeta: (schemas: {
|
44
|
-
from: string;
|
45
|
-
to: string;
|
46
|
-
}[], tables: {
|
47
|
-
from: NamedWithSchema;
|
48
|
-
to: NamedWithSchema;
|
49
|
-
}[], columns: {
|
50
|
-
from: {
|
51
|
-
table: string;
|
52
|
-
schema: string;
|
53
|
-
column: string;
|
54
|
-
};
|
55
|
-
to: {
|
56
|
-
table: string;
|
57
|
-
schema: string;
|
58
|
-
column: string;
|
59
|
-
};
|
60
|
-
}[]) => {
|
61
|
-
schemas: Record<string, string>;
|
62
|
-
tables: Record<string, string>;
|
63
|
-
columns: Record<string, string>;
|
64
|
-
};
|
65
|
-
export declare const schemaRenameKey: (it: string) => string;
|
66
|
-
export declare const tableRenameKey: (it: NamedWithSchema) => string;
|
67
|
-
export declare const columnRenameKey: (table: string, schema: string, column: string) => string;
|
68
|
-
export declare const kloudMeta: () => {
|
69
|
-
pg: number[];
|
70
|
-
mysql: number[];
|
71
|
-
sqlite: number[];
|
72
|
-
};
|