drizzle-kit 0.25.0-605ef48 → 0.25.0-662aa35
Sign up to get free protection for your applications and to get access to all the features.
- package/api.d.mts +100 -3
- package/api.d.ts +100 -3
- package/api.js +16079 -88314
- package/api.mjs +16079 -88311
- package/bin.cjs +1706 -617
- package/common-DYjgLS6u.d.mts +8 -0
- package/common-DYjgLS6u.d.ts +8 -0
- package/index.d.mts +9 -5
- package/index.d.ts +9 -5
- package/package.json +3 -3
- package/utils.js +29 -3
- package/utils.mjs +28 -3
package/api.d.mts
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
import { LibSQLDatabase } from 'drizzle-orm/libsql';
|
2
2
|
import { MySql2Database } from 'drizzle-orm/mysql2';
|
3
3
|
import { PgDatabase } from 'drizzle-orm/pg-core';
|
4
|
+
import { C as CasingType } from './common-DYjgLS6u.mjs';
|
4
5
|
import * as zod from 'zod';
|
5
6
|
import { TypeOf } from 'zod';
|
6
7
|
|
@@ -613,6 +614,28 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
613
614
|
columns: string[];
|
614
615
|
nullsNotDistinct: boolean;
|
615
616
|
}>>>;
|
617
|
+
policies: zod.ZodDefault<zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
618
|
+
name: zod.ZodString;
|
619
|
+
as: zod.ZodOptional<zod.ZodEnum<["PERMISSIVE", "RESTRICTIVE"]>>;
|
620
|
+
for: zod.ZodOptional<zod.ZodEnum<["ALL", "SELECT", "INSERT", "UPDATE", "DELETE"]>>;
|
621
|
+
to: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
|
622
|
+
using: zod.ZodOptional<zod.ZodString>;
|
623
|
+
withCheck: zod.ZodOptional<zod.ZodString>;
|
624
|
+
}, "strict", zod.ZodTypeAny, {
|
625
|
+
name: string;
|
626
|
+
using?: string | undefined;
|
627
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
628
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
629
|
+
to?: string[] | undefined;
|
630
|
+
withCheck?: string | undefined;
|
631
|
+
}, {
|
632
|
+
name: string;
|
633
|
+
using?: string | undefined;
|
634
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
635
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
636
|
+
to?: string[] | undefined;
|
637
|
+
withCheck?: string | undefined;
|
638
|
+
}>>>;
|
616
639
|
}, "strict", zod.ZodTypeAny, {
|
617
640
|
name: string;
|
618
641
|
columns: Record<string, {
|
@@ -676,6 +699,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
676
699
|
columns: string[];
|
677
700
|
nullsNotDistinct: boolean;
|
678
701
|
}>;
|
702
|
+
policies: Record<string, {
|
703
|
+
name: string;
|
704
|
+
using?: string | undefined;
|
705
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
706
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
707
|
+
to?: string[] | undefined;
|
708
|
+
withCheck?: string | undefined;
|
709
|
+
}>;
|
679
710
|
}, {
|
680
711
|
name: string;
|
681
712
|
columns: Record<string, {
|
@@ -739,6 +770,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
739
770
|
columns: string[];
|
740
771
|
nullsNotDistinct: boolean;
|
741
772
|
}> | undefined;
|
773
|
+
policies?: Record<string, {
|
774
|
+
name: string;
|
775
|
+
using?: string | undefined;
|
776
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
777
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
778
|
+
to?: string[] | undefined;
|
779
|
+
withCheck?: string | undefined;
|
780
|
+
}> | undefined;
|
742
781
|
}>>;
|
743
782
|
enums: zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
744
783
|
name: zod.ZodString;
|
@@ -782,6 +821,22 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
782
821
|
cache?: string | undefined;
|
783
822
|
cycle?: boolean | undefined;
|
784
823
|
}>>>;
|
824
|
+
roles: zod.ZodDefault<zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
825
|
+
name: zod.ZodString;
|
826
|
+
createDb: zod.ZodOptional<zod.ZodBoolean>;
|
827
|
+
createRole: zod.ZodOptional<zod.ZodBoolean>;
|
828
|
+
inherit: zod.ZodOptional<zod.ZodBoolean>;
|
829
|
+
}, "strict", zod.ZodTypeAny, {
|
830
|
+
name: string;
|
831
|
+
createDb?: boolean | undefined;
|
832
|
+
createRole?: boolean | undefined;
|
833
|
+
inherit?: boolean | undefined;
|
834
|
+
}, {
|
835
|
+
name: string;
|
836
|
+
createDb?: boolean | undefined;
|
837
|
+
createRole?: boolean | undefined;
|
838
|
+
inherit?: boolean | undefined;
|
839
|
+
}>>>;
|
785
840
|
_meta: zod.ZodObject<{
|
786
841
|
schemas: zod.ZodRecord<zod.ZodString, zod.ZodString>;
|
787
842
|
tables: zod.ZodRecord<zod.ZodString, zod.ZodString>;
|
@@ -914,6 +969,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
914
969
|
columns: string[];
|
915
970
|
nullsNotDistinct: boolean;
|
916
971
|
}>;
|
972
|
+
policies: Record<string, {
|
973
|
+
name: string;
|
974
|
+
using?: string | undefined;
|
975
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
976
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
977
|
+
to?: string[] | undefined;
|
978
|
+
withCheck?: string | undefined;
|
979
|
+
}>;
|
917
980
|
}>;
|
918
981
|
id: string;
|
919
982
|
prevId: string;
|
@@ -940,6 +1003,12 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
940
1003
|
cache?: string | undefined;
|
941
1004
|
cycle?: boolean | undefined;
|
942
1005
|
}>;
|
1006
|
+
roles: Record<string, {
|
1007
|
+
name: string;
|
1008
|
+
createDb?: boolean | undefined;
|
1009
|
+
createRole?: boolean | undefined;
|
1010
|
+
inherit?: boolean | undefined;
|
1011
|
+
}>;
|
943
1012
|
internal?: {
|
944
1013
|
tables: Record<string, {
|
945
1014
|
columns: Record<string, {
|
@@ -1014,6 +1083,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
1014
1083
|
columns: string[];
|
1015
1084
|
nullsNotDistinct: boolean;
|
1016
1085
|
}> | undefined;
|
1086
|
+
policies?: Record<string, {
|
1087
|
+
name: string;
|
1088
|
+
using?: string | undefined;
|
1089
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
1090
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
1091
|
+
to?: string[] | undefined;
|
1092
|
+
withCheck?: string | undefined;
|
1093
|
+
}> | undefined;
|
1017
1094
|
}>;
|
1018
1095
|
id: string;
|
1019
1096
|
prevId: string;
|
@@ -1050,6 +1127,12 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
1050
1127
|
cache?: string | undefined;
|
1051
1128
|
cycle?: boolean | undefined;
|
1052
1129
|
}> | undefined;
|
1130
|
+
roles?: Record<string, {
|
1131
|
+
name: string;
|
1132
|
+
createDb?: boolean | undefined;
|
1133
|
+
createRole?: boolean | undefined;
|
1134
|
+
inherit?: boolean | undefined;
|
1135
|
+
}> | undefined;
|
1053
1136
|
}>;
|
1054
1137
|
type PgSchema = TypeOf<typeof pgSchema>;
|
1055
1138
|
|
@@ -1395,7 +1478,7 @@ type SQLiteSchema = TypeOf<typeof schema>;
|
|
1395
1478
|
type DrizzleSnapshotJSON = PgSchema;
|
1396
1479
|
type DrizzleSQLiteSnapshotJSON = SQLiteSchema;
|
1397
1480
|
type DrizzleMySQLSnapshotJSON = MySqlSchema;
|
1398
|
-
declare const generateDrizzleJson: (imports: Record<string, unknown>, prevId?: string, schemaFilters?: string[]) => PgSchema;
|
1481
|
+
declare const generateDrizzleJson: (imports: Record<string, unknown>, prevId?: string, schemaFilters?: string[], casing?: CasingType) => PgSchema;
|
1399
1482
|
declare const generateMigration: (prev: DrizzleSnapshotJSON, cur: DrizzleSnapshotJSON) => Promise<string[]>;
|
1400
1483
|
declare const pushSchema: (imports: Record<string, unknown>, drizzleInstance: PgDatabase<any>, schemaFilters?: string[]) => Promise<{
|
1401
1484
|
hasDataLoss: boolean;
|
@@ -1403,7 +1486,7 @@ declare const pushSchema: (imports: Record<string, unknown>, drizzleInstance: Pg
|
|
1403
1486
|
statementsToExecute: string[];
|
1404
1487
|
apply: () => Promise<void>;
|
1405
1488
|
}>;
|
1406
|
-
declare const generateSQLiteDrizzleJson: (imports: Record<string, unknown>, prevId?: string) => Promise<SQLiteSchema>;
|
1489
|
+
declare const generateSQLiteDrizzleJson: (imports: Record<string, unknown>, prevId?: string, casing?: CasingType) => Promise<SQLiteSchema>;
|
1407
1490
|
declare const generateSQLiteMigration: (prev: DrizzleSQLiteSnapshotJSON, cur: DrizzleSQLiteSnapshotJSON) => Promise<string[]>;
|
1408
1491
|
declare const pushSQLiteSchema: (imports: Record<string, unknown>, drizzleInstance: LibSQLDatabase<any>) => Promise<{
|
1409
1492
|
hasDataLoss: boolean;
|
@@ -1411,7 +1494,7 @@ declare const pushSQLiteSchema: (imports: Record<string, unknown>, drizzleInstan
|
|
1411
1494
|
statementsToExecute: string[];
|
1412
1495
|
apply: () => Promise<void>;
|
1413
1496
|
}>;
|
1414
|
-
declare const generateMySQLDrizzleJson: (imports: Record<string, unknown>, prevId?: string) => Promise<MySqlSchema>;
|
1497
|
+
declare const generateMySQLDrizzleJson: (imports: Record<string, unknown>, prevId?: string, casing?: CasingType) => Promise<MySqlSchema>;
|
1415
1498
|
declare const generateMySQLMigration: (prev: DrizzleMySQLSnapshotJSON, cur: DrizzleMySQLSnapshotJSON) => Promise<string[]>;
|
1416
1499
|
declare const pushMySQLSchema: (imports: Record<string, unknown>, drizzleInstance: MySql2Database<any>, databaseName: string) => Promise<{
|
1417
1500
|
hasDataLoss: boolean;
|
@@ -1485,6 +1568,14 @@ declare const upPgSnapshot: (snapshot: Record<string, unknown>) => {
|
|
1485
1568
|
columns: string[];
|
1486
1569
|
nullsNotDistinct: boolean;
|
1487
1570
|
}>;
|
1571
|
+
policies: Record<string, {
|
1572
|
+
name: string;
|
1573
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
1574
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
1575
|
+
to?: string[] | undefined;
|
1576
|
+
using?: string | undefined;
|
1577
|
+
withCheck?: string | undefined;
|
1578
|
+
}>;
|
1488
1579
|
}>;
|
1489
1580
|
enums: Record<string, {
|
1490
1581
|
values: string[];
|
@@ -1502,6 +1593,12 @@ declare const upPgSnapshot: (snapshot: Record<string, unknown>) => {
|
|
1502
1593
|
cache?: string | undefined;
|
1503
1594
|
cycle?: boolean | undefined;
|
1504
1595
|
}>;
|
1596
|
+
roles: Record<string, {
|
1597
|
+
name: string;
|
1598
|
+
createDb?: boolean | undefined;
|
1599
|
+
createRole?: boolean | undefined;
|
1600
|
+
inherit?: boolean | undefined;
|
1601
|
+
}>;
|
1505
1602
|
_meta: {
|
1506
1603
|
tables: Record<string, string>;
|
1507
1604
|
columns: Record<string, string>;
|
package/api.d.ts
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
import { LibSQLDatabase } from 'drizzle-orm/libsql';
|
2
2
|
import { MySql2Database } from 'drizzle-orm/mysql2';
|
3
3
|
import { PgDatabase } from 'drizzle-orm/pg-core';
|
4
|
+
import { C as CasingType } from './common-DYjgLS6u.js';
|
4
5
|
import * as zod from 'zod';
|
5
6
|
import { TypeOf } from 'zod';
|
6
7
|
|
@@ -613,6 +614,28 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
613
614
|
columns: string[];
|
614
615
|
nullsNotDistinct: boolean;
|
615
616
|
}>>>;
|
617
|
+
policies: zod.ZodDefault<zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
618
|
+
name: zod.ZodString;
|
619
|
+
as: zod.ZodOptional<zod.ZodEnum<["PERMISSIVE", "RESTRICTIVE"]>>;
|
620
|
+
for: zod.ZodOptional<zod.ZodEnum<["ALL", "SELECT", "INSERT", "UPDATE", "DELETE"]>>;
|
621
|
+
to: zod.ZodOptional<zod.ZodArray<zod.ZodString, "many">>;
|
622
|
+
using: zod.ZodOptional<zod.ZodString>;
|
623
|
+
withCheck: zod.ZodOptional<zod.ZodString>;
|
624
|
+
}, "strict", zod.ZodTypeAny, {
|
625
|
+
name: string;
|
626
|
+
using?: string | undefined;
|
627
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
628
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
629
|
+
to?: string[] | undefined;
|
630
|
+
withCheck?: string | undefined;
|
631
|
+
}, {
|
632
|
+
name: string;
|
633
|
+
using?: string | undefined;
|
634
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
635
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
636
|
+
to?: string[] | undefined;
|
637
|
+
withCheck?: string | undefined;
|
638
|
+
}>>>;
|
616
639
|
}, "strict", zod.ZodTypeAny, {
|
617
640
|
name: string;
|
618
641
|
columns: Record<string, {
|
@@ -676,6 +699,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
676
699
|
columns: string[];
|
677
700
|
nullsNotDistinct: boolean;
|
678
701
|
}>;
|
702
|
+
policies: Record<string, {
|
703
|
+
name: string;
|
704
|
+
using?: string | undefined;
|
705
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
706
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
707
|
+
to?: string[] | undefined;
|
708
|
+
withCheck?: string | undefined;
|
709
|
+
}>;
|
679
710
|
}, {
|
680
711
|
name: string;
|
681
712
|
columns: Record<string, {
|
@@ -739,6 +770,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
739
770
|
columns: string[];
|
740
771
|
nullsNotDistinct: boolean;
|
741
772
|
}> | undefined;
|
773
|
+
policies?: Record<string, {
|
774
|
+
name: string;
|
775
|
+
using?: string | undefined;
|
776
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
777
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
778
|
+
to?: string[] | undefined;
|
779
|
+
withCheck?: string | undefined;
|
780
|
+
}> | undefined;
|
742
781
|
}>>;
|
743
782
|
enums: zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
744
783
|
name: zod.ZodString;
|
@@ -782,6 +821,22 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
782
821
|
cache?: string | undefined;
|
783
822
|
cycle?: boolean | undefined;
|
784
823
|
}>>>;
|
824
|
+
roles: zod.ZodDefault<zod.ZodRecord<zod.ZodString, zod.ZodObject<{
|
825
|
+
name: zod.ZodString;
|
826
|
+
createDb: zod.ZodOptional<zod.ZodBoolean>;
|
827
|
+
createRole: zod.ZodOptional<zod.ZodBoolean>;
|
828
|
+
inherit: zod.ZodOptional<zod.ZodBoolean>;
|
829
|
+
}, "strict", zod.ZodTypeAny, {
|
830
|
+
name: string;
|
831
|
+
createDb?: boolean | undefined;
|
832
|
+
createRole?: boolean | undefined;
|
833
|
+
inherit?: boolean | undefined;
|
834
|
+
}, {
|
835
|
+
name: string;
|
836
|
+
createDb?: boolean | undefined;
|
837
|
+
createRole?: boolean | undefined;
|
838
|
+
inherit?: boolean | undefined;
|
839
|
+
}>>>;
|
785
840
|
_meta: zod.ZodObject<{
|
786
841
|
schemas: zod.ZodRecord<zod.ZodString, zod.ZodString>;
|
787
842
|
tables: zod.ZodRecord<zod.ZodString, zod.ZodString>;
|
@@ -914,6 +969,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
914
969
|
columns: string[];
|
915
970
|
nullsNotDistinct: boolean;
|
916
971
|
}>;
|
972
|
+
policies: Record<string, {
|
973
|
+
name: string;
|
974
|
+
using?: string | undefined;
|
975
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
976
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
977
|
+
to?: string[] | undefined;
|
978
|
+
withCheck?: string | undefined;
|
979
|
+
}>;
|
917
980
|
}>;
|
918
981
|
id: string;
|
919
982
|
prevId: string;
|
@@ -940,6 +1003,12 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
940
1003
|
cache?: string | undefined;
|
941
1004
|
cycle?: boolean | undefined;
|
942
1005
|
}>;
|
1006
|
+
roles: Record<string, {
|
1007
|
+
name: string;
|
1008
|
+
createDb?: boolean | undefined;
|
1009
|
+
createRole?: boolean | undefined;
|
1010
|
+
inherit?: boolean | undefined;
|
1011
|
+
}>;
|
943
1012
|
internal?: {
|
944
1013
|
tables: Record<string, {
|
945
1014
|
columns: Record<string, {
|
@@ -1014,6 +1083,14 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
1014
1083
|
columns: string[];
|
1015
1084
|
nullsNotDistinct: boolean;
|
1016
1085
|
}> | undefined;
|
1086
|
+
policies?: Record<string, {
|
1087
|
+
name: string;
|
1088
|
+
using?: string | undefined;
|
1089
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
1090
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
1091
|
+
to?: string[] | undefined;
|
1092
|
+
withCheck?: string | undefined;
|
1093
|
+
}> | undefined;
|
1017
1094
|
}>;
|
1018
1095
|
id: string;
|
1019
1096
|
prevId: string;
|
@@ -1050,6 +1127,12 @@ declare const pgSchema: zod.ZodObject<zod.objectUtil.extendShape<{
|
|
1050
1127
|
cache?: string | undefined;
|
1051
1128
|
cycle?: boolean | undefined;
|
1052
1129
|
}> | undefined;
|
1130
|
+
roles?: Record<string, {
|
1131
|
+
name: string;
|
1132
|
+
createDb?: boolean | undefined;
|
1133
|
+
createRole?: boolean | undefined;
|
1134
|
+
inherit?: boolean | undefined;
|
1135
|
+
}> | undefined;
|
1053
1136
|
}>;
|
1054
1137
|
type PgSchema = TypeOf<typeof pgSchema>;
|
1055
1138
|
|
@@ -1395,7 +1478,7 @@ type SQLiteSchema = TypeOf<typeof schema>;
|
|
1395
1478
|
type DrizzleSnapshotJSON = PgSchema;
|
1396
1479
|
type DrizzleSQLiteSnapshotJSON = SQLiteSchema;
|
1397
1480
|
type DrizzleMySQLSnapshotJSON = MySqlSchema;
|
1398
|
-
declare const generateDrizzleJson: (imports: Record<string, unknown>, prevId?: string, schemaFilters?: string[]) => PgSchema;
|
1481
|
+
declare const generateDrizzleJson: (imports: Record<string, unknown>, prevId?: string, schemaFilters?: string[], casing?: CasingType) => PgSchema;
|
1399
1482
|
declare const generateMigration: (prev: DrizzleSnapshotJSON, cur: DrizzleSnapshotJSON) => Promise<string[]>;
|
1400
1483
|
declare const pushSchema: (imports: Record<string, unknown>, drizzleInstance: PgDatabase<any>, schemaFilters?: string[]) => Promise<{
|
1401
1484
|
hasDataLoss: boolean;
|
@@ -1403,7 +1486,7 @@ declare const pushSchema: (imports: Record<string, unknown>, drizzleInstance: Pg
|
|
1403
1486
|
statementsToExecute: string[];
|
1404
1487
|
apply: () => Promise<void>;
|
1405
1488
|
}>;
|
1406
|
-
declare const generateSQLiteDrizzleJson: (imports: Record<string, unknown>, prevId?: string) => Promise<SQLiteSchema>;
|
1489
|
+
declare const generateSQLiteDrizzleJson: (imports: Record<string, unknown>, prevId?: string, casing?: CasingType) => Promise<SQLiteSchema>;
|
1407
1490
|
declare const generateSQLiteMigration: (prev: DrizzleSQLiteSnapshotJSON, cur: DrizzleSQLiteSnapshotJSON) => Promise<string[]>;
|
1408
1491
|
declare const pushSQLiteSchema: (imports: Record<string, unknown>, drizzleInstance: LibSQLDatabase<any>) => Promise<{
|
1409
1492
|
hasDataLoss: boolean;
|
@@ -1411,7 +1494,7 @@ declare const pushSQLiteSchema: (imports: Record<string, unknown>, drizzleInstan
|
|
1411
1494
|
statementsToExecute: string[];
|
1412
1495
|
apply: () => Promise<void>;
|
1413
1496
|
}>;
|
1414
|
-
declare const generateMySQLDrizzleJson: (imports: Record<string, unknown>, prevId?: string) => Promise<MySqlSchema>;
|
1497
|
+
declare const generateMySQLDrizzleJson: (imports: Record<string, unknown>, prevId?: string, casing?: CasingType) => Promise<MySqlSchema>;
|
1415
1498
|
declare const generateMySQLMigration: (prev: DrizzleMySQLSnapshotJSON, cur: DrizzleMySQLSnapshotJSON) => Promise<string[]>;
|
1416
1499
|
declare const pushMySQLSchema: (imports: Record<string, unknown>, drizzleInstance: MySql2Database<any>, databaseName: string) => Promise<{
|
1417
1500
|
hasDataLoss: boolean;
|
@@ -1485,6 +1568,14 @@ declare const upPgSnapshot: (snapshot: Record<string, unknown>) => {
|
|
1485
1568
|
columns: string[];
|
1486
1569
|
nullsNotDistinct: boolean;
|
1487
1570
|
}>;
|
1571
|
+
policies: Record<string, {
|
1572
|
+
name: string;
|
1573
|
+
as?: "PERMISSIVE" | "RESTRICTIVE" | undefined;
|
1574
|
+
for?: "ALL" | "SELECT" | "INSERT" | "UPDATE" | "DELETE" | undefined;
|
1575
|
+
to?: string[] | undefined;
|
1576
|
+
using?: string | undefined;
|
1577
|
+
withCheck?: string | undefined;
|
1578
|
+
}>;
|
1488
1579
|
}>;
|
1489
1580
|
enums: Record<string, {
|
1490
1581
|
values: string[];
|
@@ -1502,6 +1593,12 @@ declare const upPgSnapshot: (snapshot: Record<string, unknown>) => {
|
|
1502
1593
|
cache?: string | undefined;
|
1503
1594
|
cycle?: boolean | undefined;
|
1504
1595
|
}>;
|
1596
|
+
roles: Record<string, {
|
1597
|
+
name: string;
|
1598
|
+
createDb?: boolean | undefined;
|
1599
|
+
createRole?: boolean | undefined;
|
1600
|
+
inherit?: boolean | undefined;
|
1601
|
+
}>;
|
1505
1602
|
_meta: {
|
1506
1603
|
tables: Record<string, string>;
|
1507
1604
|
columns: Record<string, string>;
|