@pgpmjs/core 6.3.2 → 6.4.1
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/core/class/pgpm.d.ts
CHANGED
|
@@ -34,6 +34,13 @@ export interface InitModuleOptions {
|
|
|
34
34
|
* Defaults to true for backward compatibility.
|
|
35
35
|
*/
|
|
36
36
|
pgpm?: boolean;
|
|
37
|
+
/**
|
|
38
|
+
* Optional Inquirerer instance to reuse for prompting during template scaffolding.
|
|
39
|
+
* If provided, prevents creating a duplicate instance on process.stdin which
|
|
40
|
+
* would cause double-echoed keystrokes and other input conflicts.
|
|
41
|
+
* The caller retains ownership and is responsible for closing it.
|
|
42
|
+
*/
|
|
43
|
+
prompter?: import('inquirerer').Inquirerer;
|
|
37
44
|
}
|
|
38
45
|
export declare class PgpmPackage {
|
|
39
46
|
cwd: string;
|
package/core/class/pgpm.js
CHANGED
|
@@ -397,7 +397,8 @@ class PgpmPackage {
|
|
|
397
397
|
noTty: options.noTty ?? false,
|
|
398
398
|
cacheTtlMs: options.cacheTtlMs ?? template_scaffold_1.DEFAULT_TEMPLATE_TTL_MS,
|
|
399
399
|
toolName: options.toolName ?? template_scaffold_1.DEFAULT_TEMPLATE_TOOL_NAME,
|
|
400
|
-
cwd: this.cwd
|
|
400
|
+
cwd: this.cwd,
|
|
401
|
+
prompter: options.prompter,
|
|
401
402
|
});
|
|
402
403
|
// Only create pgpm files (pgpm.plan, .control, deploy/revert/verify dirs) for pgpm-managed modules
|
|
403
404
|
if (isPgpmModule) {
|
package/esm/core/class/pgpm.js
CHANGED
|
@@ -358,7 +358,8 @@ export class PgpmPackage {
|
|
|
358
358
|
noTty: options.noTty ?? false,
|
|
359
359
|
cacheTtlMs: options.cacheTtlMs ?? DEFAULT_TEMPLATE_TTL_MS,
|
|
360
360
|
toolName: options.toolName ?? DEFAULT_TEMPLATE_TOOL_NAME,
|
|
361
|
-
cwd: this.cwd
|
|
361
|
+
cwd: this.cwd,
|
|
362
|
+
prompter: options.prompter,
|
|
362
363
|
});
|
|
363
364
|
// Only create pgpm files (pgpm.plan, .control, deploy/revert/verify dirs) for pgpm-managed modules
|
|
364
365
|
if (isPgpmModule) {
|
|
@@ -199,34 +199,6 @@ const config = {
|
|
|
199
199
|
security: 'int'
|
|
200
200
|
}
|
|
201
201
|
},
|
|
202
|
-
limit_function: {
|
|
203
|
-
schema: 'metaschema_public',
|
|
204
|
-
table: 'limit_function',
|
|
205
|
-
fields: {
|
|
206
|
-
id: 'uuid',
|
|
207
|
-
database_id: 'uuid',
|
|
208
|
-
table_id: 'uuid',
|
|
209
|
-
name: 'text',
|
|
210
|
-
label: 'text',
|
|
211
|
-
description: 'text',
|
|
212
|
-
data: 'jsonb',
|
|
213
|
-
security: 'int'
|
|
214
|
-
}
|
|
215
|
-
},
|
|
216
|
-
procedure: {
|
|
217
|
-
schema: 'metaschema_public',
|
|
218
|
-
table: 'procedure',
|
|
219
|
-
fields: {
|
|
220
|
-
id: 'uuid',
|
|
221
|
-
database_id: 'uuid',
|
|
222
|
-
name: 'text',
|
|
223
|
-
argnames: 'text[]',
|
|
224
|
-
argtypes: 'text[]',
|
|
225
|
-
argdefaults: 'text[]',
|
|
226
|
-
lang_name: 'text',
|
|
227
|
-
definition: 'text'
|
|
228
|
-
}
|
|
229
|
-
},
|
|
230
202
|
foreign_key_constraint: {
|
|
231
203
|
schema: 'metaschema_public',
|
|
232
204
|
table: 'foreign_key_constraint',
|
|
@@ -988,8 +960,6 @@ export const exportMeta = async ({ opts, dbname, database_id }) => {
|
|
|
988
960
|
await queryAndParse('trigger', `SELECT * FROM metaschema_public.trigger WHERE database_id = $1`);
|
|
989
961
|
await queryAndParse('trigger_function', `SELECT * FROM metaschema_public.trigger_function WHERE database_id = $1`);
|
|
990
962
|
await queryAndParse('rls_function', `SELECT * FROM metaschema_public.rls_function WHERE database_id = $1`);
|
|
991
|
-
await queryAndParse('limit_function', `SELECT * FROM metaschema_public.limit_function WHERE database_id = $1`);
|
|
992
|
-
await queryAndParse('procedure', `SELECT * FROM metaschema_public.procedure WHERE database_id = $1`);
|
|
993
963
|
await queryAndParse('foreign_key_constraint', `SELECT * FROM metaschema_public.foreign_key_constraint WHERE database_id = $1`);
|
|
994
964
|
await queryAndParse('primary_key_constraint', `SELECT * FROM metaschema_public.primary_key_constraint WHERE database_id = $1`);
|
|
995
965
|
await queryAndParse('unique_constraint', `SELECT * FROM metaschema_public.unique_constraint WHERE database_id = $1`);
|
package/export/export-meta.js
CHANGED
|
@@ -202,34 +202,6 @@ const config = {
|
|
|
202
202
|
security: 'int'
|
|
203
203
|
}
|
|
204
204
|
},
|
|
205
|
-
limit_function: {
|
|
206
|
-
schema: 'metaschema_public',
|
|
207
|
-
table: 'limit_function',
|
|
208
|
-
fields: {
|
|
209
|
-
id: 'uuid',
|
|
210
|
-
database_id: 'uuid',
|
|
211
|
-
table_id: 'uuid',
|
|
212
|
-
name: 'text',
|
|
213
|
-
label: 'text',
|
|
214
|
-
description: 'text',
|
|
215
|
-
data: 'jsonb',
|
|
216
|
-
security: 'int'
|
|
217
|
-
}
|
|
218
|
-
},
|
|
219
|
-
procedure: {
|
|
220
|
-
schema: 'metaschema_public',
|
|
221
|
-
table: 'procedure',
|
|
222
|
-
fields: {
|
|
223
|
-
id: 'uuid',
|
|
224
|
-
database_id: 'uuid',
|
|
225
|
-
name: 'text',
|
|
226
|
-
argnames: 'text[]',
|
|
227
|
-
argtypes: 'text[]',
|
|
228
|
-
argdefaults: 'text[]',
|
|
229
|
-
lang_name: 'text',
|
|
230
|
-
definition: 'text'
|
|
231
|
-
}
|
|
232
|
-
},
|
|
233
205
|
foreign_key_constraint: {
|
|
234
206
|
schema: 'metaschema_public',
|
|
235
207
|
table: 'foreign_key_constraint',
|
|
@@ -991,8 +963,6 @@ const exportMeta = async ({ opts, dbname, database_id }) => {
|
|
|
991
963
|
await queryAndParse('trigger', `SELECT * FROM metaschema_public.trigger WHERE database_id = $1`);
|
|
992
964
|
await queryAndParse('trigger_function', `SELECT * FROM metaschema_public.trigger_function WHERE database_id = $1`);
|
|
993
965
|
await queryAndParse('rls_function', `SELECT * FROM metaschema_public.rls_function WHERE database_id = $1`);
|
|
994
|
-
await queryAndParse('limit_function', `SELECT * FROM metaschema_public.limit_function WHERE database_id = $1`);
|
|
995
|
-
await queryAndParse('procedure', `SELECT * FROM metaschema_public.procedure WHERE database_id = $1`);
|
|
996
966
|
await queryAndParse('foreign_key_constraint', `SELECT * FROM metaschema_public.foreign_key_constraint WHERE database_id = $1`);
|
|
997
967
|
await queryAndParse('primary_key_constraint', `SELECT * FROM metaschema_public.primary_key_constraint WHERE database_id = $1`);
|
|
998
968
|
await queryAndParse('unique_constraint', `SELECT * FROM metaschema_public.unique_constraint WHERE database_id = $1`);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pgpmjs/core",
|
|
3
|
-
"version": "6.
|
|
3
|
+
"version": "6.4.1",
|
|
4
4
|
"author": "Constructive <developers@constructive.io>",
|
|
5
5
|
"description": "PGPM Package and Migration Tools",
|
|
6
6
|
"main": "index.js",
|
|
@@ -44,7 +44,7 @@
|
|
|
44
44
|
"@pgsql/types": "^17.6.2",
|
|
45
45
|
"@types/pg": "^8.16.0",
|
|
46
46
|
"copyfiles": "^2.4.1",
|
|
47
|
-
"inquirerer": "^4.
|
|
47
|
+
"inquirerer": "^4.5.2",
|
|
48
48
|
"makage": "^0.1.12"
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
@@ -52,8 +52,8 @@
|
|
|
52
52
|
"@pgpmjs/logger": "^2.2.0",
|
|
53
53
|
"@pgpmjs/server-utils": "^3.2.0",
|
|
54
54
|
"@pgpmjs/types": "^2.17.0",
|
|
55
|
-
"csv-to-pg": "^3.8.
|
|
56
|
-
"genomic": "^5.3.
|
|
55
|
+
"csv-to-pg": "^3.8.1",
|
|
56
|
+
"genomic": "^5.3.5",
|
|
57
57
|
"glob": "^13.0.0",
|
|
58
58
|
"komoji": "^0.8.0",
|
|
59
59
|
"minimatch": "^10.1.1",
|
|
@@ -65,5 +65,5 @@
|
|
|
65
65
|
"pgsql-parser": "^17.9.11",
|
|
66
66
|
"yanse": "^0.2.0"
|
|
67
67
|
},
|
|
68
|
-
"gitHead": "
|
|
68
|
+
"gitHead": "1c9efe4ecd5a6b8daa14fe42214ecf8c5b664198"
|
|
69
69
|
}
|