silgi 0.28.3 → 0.28.5

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.
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env node
2
2
  import { defineCommand, runMain } from 'citty';
3
3
 
4
- const version = "0.28.3";
4
+ const version = "0.28.5";
5
5
  const packageJson = {
6
6
  version: version};
7
7
 
@@ -2348,13 +2348,14 @@ async function createSilgiCLI(config = {}, opts = {}) {
2348
2348
  async updateConfig(_config) {
2349
2349
  },
2350
2350
  routeRules: void 0,
2351
- adapter: void 0
2351
+ adapter: {}
2352
2352
  };
2353
2353
  if (silgi.options.database && Object.keys(silgi.options.database)?.length > 0) {
2354
2354
  for (const [key, value] of Object.entries(silgi.options.database)) {
2355
+ const { tables, ...options2 } = value;
2355
2356
  silgi.adapter[key] = createAdapter(
2356
2357
  value.tables,
2357
- value.database
2358
+ options2
2358
2359
  );
2359
2360
  }
2360
2361
  }
@@ -1,6 +1,7 @@
1
1
  import { SilgiCLI, ModuleOptionsCustom, ModuleDefinition, SilgiModule, ServiceParseModule, SilgiPreset, SilgiPresetMeta, SilgiTemplate, ResolvedSilgiTemplate, SilgiEvents } from 'silgi/types';
2
2
  import { Buffer } from 'node:buffer';
3
3
  import { ConsolaOptions, ConsolaInstance } from 'consola';
4
+ import * as rfc6902 from 'rfc6902';
4
5
  import { IncomingMessage, ServerResponse } from 'node:http';
5
6
 
6
7
  declare function hasError(type: SilgiCLI['errors'][0]['type'], silgi?: SilgiCLI): boolean;
@@ -53,6 +54,120 @@ declare function isH3(): boolean;
53
54
 
54
55
  declare function useLogger(tag?: string, options?: Partial<ConsolaOptions>): ConsolaInstance;
55
56
 
57
+ /**
58
+ * Migration bilgisi
59
+ */
60
+ interface MigrationInfo {
61
+ /** Migration zaman damgası */
62
+ timestamp: number;
63
+ /** Migration dosya adı */
64
+ file: string;
65
+ /** Migration oluşturulma tarihi */
66
+ created: string;
67
+ /** Migration açıklaması */
68
+ description?: string;
69
+ /** Patch formatında mı? */
70
+ isPatch?: boolean;
71
+ }
72
+ /**
73
+ * İzin migration verisi
74
+ */
75
+ interface PermissionMigration {
76
+ id: string;
77
+ key: string;
78
+ description: string;
79
+ name: string;
80
+ permissions: string;
81
+ }
82
+ /**
83
+ * JSON Patch formatı (RFC6902)
84
+ */
85
+ type JsonPatch = Array<rfc6902.Operation>;
86
+ /**
87
+ * Migration durumu
88
+ */
89
+ declare enum MigrationStatus {
90
+ SUCCESS = "success",
91
+ ERROR = "error",
92
+ SKIPPED = "skipped"
93
+ }
94
+ /**
95
+ * Migration options
96
+ */
97
+ interface MigrationOptions {
98
+ /** Migration açıklaması (opsiyonel) */
99
+ description?: string;
100
+ /** Değişiklikler için log göster */
101
+ verbose?: boolean;
102
+ /** JSON dosyasını pretty-print formatında kaydet */
103
+ prettyPrint?: boolean;
104
+ /** Patch formatını kullanmalı mı? */
105
+ usePatch?: boolean;
106
+ /** Değişiklik yoksa dosya oluşturma */
107
+ skipIfNoChanges?: boolean;
108
+ }
109
+ /**
110
+ * Migration başlatma sonucu
111
+ */
112
+ interface MigrationResult {
113
+ /** İşlem başarılı mı? */
114
+ success: boolean;
115
+ /** Migration durumu */
116
+ status: MigrationStatus;
117
+ /** Migration dosya yolu (başarılıysa) */
118
+ filePath?: string;
119
+ /** Migration zaman damgası (başarılıysa) */
120
+ timestamp?: number;
121
+ /** Hata mesajı (başarısızsa) */
122
+ error?: string;
123
+ /** Patch türünde mi? */
124
+ isPatch?: boolean;
125
+ /** Migration verisi */
126
+ data?: PermissionMigration[] | JsonPatch;
127
+ }
128
+ /**
129
+ * Migration oluşturur
130
+ *
131
+ * @param data Migration verisi
132
+ * @param directoryPath Migration dizini
133
+ * @param fileNamePrefix Dosya adı öneki
134
+ * @param options Migration seçenekleri
135
+ * @returns Migration sonucu
136
+ */
137
+ declare function generateMigration<T>(data: T, directoryPath: string, fileNamePrefix?: string, options?: MigrationOptions): Promise<MigrationResult>;
138
+ /**
139
+ * Belirli bir migration dosyasının bilgilerini alır
140
+ *
141
+ * @param migrationsDir Migration dizini
142
+ * @param fileName Dosya adı (belirtilmezse son migration dosyası)
143
+ * @returns Migration bilgileri ve verisi
144
+ */
145
+ declare function getMigration(migrationsDir: string, fileName?: string): Promise<MigrationResult>;
146
+ /**
147
+ * Tüm migration dosyalarını listeler
148
+ *
149
+ * @param migrationsDir Migration dizini
150
+ * @param filePrefix Dosya adı öneki filtreleme (opsiyonel)
151
+ * @returns Migration listesi
152
+ */
153
+ declare function listMigrations(migrationsDir: string, filePrefix?: string): Promise<MigrationInfo[]>;
154
+ /**
155
+ * Migration'ları ileri uygular (son duruma getirir)
156
+ *
157
+ * @param migrationsDir Migration dizini
158
+ * @param targetTimestamp Hedef zaman damgası (belirtilmezse son migration'a kadar)
159
+ * @returns Migration sonucu
160
+ */
161
+ declare function migrationUp(migrationsDir: string, targetTimestamp?: number): Promise<MigrationResult>;
162
+ /**
163
+ * Migration'ları geri alır (belirtilen noktaya kadar veya bir önceki migration'a)
164
+ *
165
+ * @param migrationsDir Migration dizini
166
+ * @param targetTimestamp Hedef zaman damgası (belirtilmezse bir önceki migration'a döner)
167
+ * @returns Migration sonucu
168
+ */
169
+ declare function migrationDown(migrationsDir: string, targetTimestamp?: number): Promise<MigrationResult>;
170
+
56
171
  /**
57
172
  * Define a Silgi module, automatically merging defaults with user provided options, installing
58
173
  * any hooks that are provided, and calling an optional setup function for full control.
@@ -173,5 +288,5 @@ declare function hasInstalledModule(moduleKey: string, silgi?: SilgiCLI): boolea
173
288
  declare const baseHeaderBannerComment: string[];
174
289
  declare function processFilePath(src: string): string;
175
290
 
176
- export { MODE_RE, addTemplate, baseHeaderBannerComment, createFunction, createFunctionConfigs, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, formatFunctions, genEnsureSafeVar, getAllEntries, getIpAddress, hasError, hasInstalledModule, hasSilgiModule, hash, ipAddress, isDirectory, isH3, isNitro, isNuxt, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, writeFile };
177
- export type { FunctionConfig };
291
+ export { MODE_RE, MigrationStatus, addTemplate, baseHeaderBannerComment, createFunction, createFunctionConfigs, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, formatFunctions, genEnsureSafeVar, generateMigration, getAllEntries, getIpAddress, getMigration, hasError, hasInstalledModule, hasSilgiModule, hash, ipAddress, isDirectory, isH3, isNitro, isNuxt, listMigrations, migrationDown, migrationUp, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, writeFile };
292
+ export type { FunctionConfig, JsonPatch, MigrationInfo, MigrationOptions, MigrationResult, PermissionMigration };
@@ -1,18 +1,19 @@
1
1
  import { tryUseSilgiCLI, useSilgiCLI, useSilgi } from 'silgi';
2
2
  import { pathToFileURL, fileURLToPath } from 'node:url';
3
3
  import { resolvePath as resolvePath$1 } from 'mlly';
4
- import fsp from 'node:fs/promises';
4
+ import fsp, { mkdir, readFile, writeFile as writeFile$1 } from 'node:fs/promises';
5
5
  import consola, { consola as consola$1 } from 'consola';
6
- import { relative, resolve, dirname, normalize, isAbsolute, join, parse, basename } from 'pathe';
6
+ import { relative, resolve, dirname, join, normalize, isAbsolute, parse, basename } from 'pathe';
7
7
  import { colors } from 'consola/utils';
8
8
  import { getProperty } from 'dot-prop';
9
9
  import { genString, genObjectFromRaw, genObjectFromValues, genObjectFromRawEntries } from 'knitwork';
10
10
  import { hash as hash$1 } from 'ohash';
11
11
  import { camelCase } from 'scule';
12
+ import { existsSync, promises } from 'node:fs';
13
+ import * as rfc6902 from 'rfc6902';
12
14
  import { defu } from 'defu';
13
15
  import { c as checkSilgiCompatibility } from '../cli/compatibility.mjs';
14
16
  import { withLeadingSlash } from 'ufo';
15
- import { existsSync, promises } from 'node:fs';
16
17
  import { resolveAlias as resolveAlias$1 } from 'pathe/utils';
17
18
  import { hash as hash$2 } from 'silgi/kit';
18
19
  import 'semver/functions/satisfies.js';
@@ -238,6 +239,322 @@ function useLogger(tag, options = {}) {
238
239
  return tag ? logger.create(options).withTag(tag) : logger;
239
240
  }
240
241
 
242
+ var MigrationStatus = /* @__PURE__ */ ((MigrationStatus2) => {
243
+ MigrationStatus2["SUCCESS"] = "success";
244
+ MigrationStatus2["ERROR"] = "error";
245
+ MigrationStatus2["SKIPPED"] = "skipped";
246
+ return MigrationStatus2;
247
+ })(MigrationStatus || {});
248
+ async function generateMigration(data, directoryPath, fileNamePrefix = "data_", options = {}) {
249
+ const {
250
+ description,
251
+ verbose = false,
252
+ prettyPrint = true,
253
+ usePatch = true,
254
+ skipIfNoChanges = true
255
+ } = options;
256
+ try {
257
+ try {
258
+ if (!existsSync(directoryPath)) {
259
+ await mkdir(directoryPath, { recursive: true });
260
+ }
261
+ } catch (error) {
262
+ return {
263
+ success: false,
264
+ status: "error" /* ERROR */,
265
+ error: `Dizin olu\u015Fturulamad\u0131: ${error}`
266
+ };
267
+ }
268
+ const latestPath = join(directoryPath, "latest.json");
269
+ let existingData = null;
270
+ let hasChanges = true;
271
+ let patch = [];
272
+ if (existsSync(latestPath)) {
273
+ try {
274
+ const latestContent = await readFile(latestPath, "utf-8");
275
+ const latestInfo2 = JSON.parse(latestContent);
276
+ if (latestInfo2?.file) {
277
+ const existingFilePath = join(directoryPath, latestInfo2.file);
278
+ if (existsSync(existingFilePath)) {
279
+ const fileContent2 = await readFile(existingFilePath, "utf-8");
280
+ try {
281
+ if (latestInfo2.isPatch) {
282
+ const result = await migrationUp(directoryPath);
283
+ if (result.success && result.data) {
284
+ existingData = result.data;
285
+ }
286
+ } else {
287
+ existingData = JSON.parse(fileContent2);
288
+ }
289
+ if (existingData) {
290
+ patch = rfc6902.createPatch(existingData, data);
291
+ hasChanges = patch.length > 0;
292
+ if (verbose && hasChanges) {
293
+ console.warn("De\u011Fi\u015Fiklikler tespit edildi:", patch);
294
+ }
295
+ }
296
+ } catch (err) {
297
+ console.warn(`Migration verisi i\u015Flenirken hata: ${err}`);
298
+ }
299
+ }
300
+ }
301
+ } catch (error) {
302
+ console.warn(`Latest bilgisi okunamad\u0131: ${error}`);
303
+ }
304
+ }
305
+ if (!hasChanges && existingData !== null && skipIfNoChanges) {
306
+ if (verbose) {
307
+ console.warn("De\u011Fi\u015Fiklik yok, migration olu\u015Fturulmad\u0131.");
308
+ }
309
+ return {
310
+ success: true,
311
+ status: "skipped" /* SKIPPED */
312
+ };
313
+ }
314
+ const timestamp = Math.floor(Date.now() / 1e3);
315
+ const isPatch = usePatch && patch.length > 0 && existingData !== null;
316
+ const fileName = `${fileNamePrefix}${isPatch ? "patch_" : ""}${timestamp}.json`;
317
+ const filePath = join(directoryPath, fileName);
318
+ const fileContent = isPatch ? patch : data;
319
+ const indent = prettyPrint ? 2 : 0;
320
+ await writeFile$1(filePath, JSON.stringify(fileContent, null, indent), "utf-8");
321
+ const latestInfo = {
322
+ timestamp,
323
+ file: fileName,
324
+ created: (/* @__PURE__ */ new Date()).toISOString(),
325
+ description,
326
+ isPatch
327
+ };
328
+ await writeFile$1(latestPath, JSON.stringify(latestInfo, null, indent), "utf-8");
329
+ if (verbose) {
330
+ console.warn(`Yeni ${isPatch ? "patch" : "tam veri"} migration olu\u015Fturuldu: ${fileName}`);
331
+ }
332
+ return {
333
+ success: true,
334
+ status: "success" /* SUCCESS */,
335
+ filePath,
336
+ timestamp,
337
+ isPatch,
338
+ data: fileContent
339
+ };
340
+ } catch (error) {
341
+ return {
342
+ success: false,
343
+ status: "error" /* ERROR */,
344
+ error: `Migration olu\u015Fturma hatas\u0131: ${error instanceof Error ? error.message : String(error)}`
345
+ };
346
+ }
347
+ }
348
+ async function getMigration(migrationsDir, fileName) {
349
+ try {
350
+ if (!existsSync(migrationsDir)) {
351
+ return {
352
+ success: false,
353
+ status: "error" /* ERROR */,
354
+ error: `Migration dizini bulunamad\u0131: ${migrationsDir}`
355
+ };
356
+ }
357
+ if (!fileName) {
358
+ const latestPath = join(migrationsDir, "latest.json");
359
+ if (!existsSync(latestPath)) {
360
+ return {
361
+ success: false,
362
+ status: "error" /* ERROR */,
363
+ error: `Latest bilgisi bulunamad\u0131: ${latestPath}`
364
+ };
365
+ }
366
+ const latestContent = await readFile(latestPath, "utf-8");
367
+ const latestInfo = JSON.parse(latestContent);
368
+ fileName = latestInfo.file;
369
+ }
370
+ const migrationPath = join(migrationsDir, fileName);
371
+ if (!existsSync(migrationPath)) {
372
+ return {
373
+ success: false,
374
+ status: "error" /* ERROR */,
375
+ error: `Migration dosyas\u0131 bulunamad\u0131: ${migrationPath}`
376
+ };
377
+ }
378
+ const migrationContent = await readFile(migrationPath, "utf-8");
379
+ const data = JSON.parse(migrationContent);
380
+ const isPatch = fileName.includes("_patch_");
381
+ const timestampMatch = fileName.match(/(\d+)\.json$/);
382
+ const timestamp = timestampMatch ? Number.parseInt(timestampMatch[1]) : void 0;
383
+ return {
384
+ success: true,
385
+ status: "success" /* SUCCESS */,
386
+ filePath: migrationPath,
387
+ timestamp,
388
+ isPatch,
389
+ data
390
+ };
391
+ } catch (error) {
392
+ return {
393
+ success: false,
394
+ status: "error" /* ERROR */,
395
+ error: `Migration bilgileri al\u0131n\u0131rken hata: ${error instanceof Error ? error.message : String(error)}`
396
+ };
397
+ }
398
+ }
399
+ async function listMigrations(migrationsDir, filePrefix) {
400
+ try {
401
+ if (!existsSync(migrationsDir)) {
402
+ return [];
403
+ }
404
+ const { readdir } = await import('node:fs/promises');
405
+ const files = await readdir(migrationsDir);
406
+ const jsonFiles = files.filter((file) => file.endsWith(".json") && file !== "latest.json");
407
+ const filteredFiles = filePrefix ? jsonFiles.filter((file) => file.startsWith(filePrefix)) : jsonFiles;
408
+ return filteredFiles.map((file) => {
409
+ const isPatch = file.includes("_patch_");
410
+ const timestampMatch = file.match(/(\d+)\.json$/);
411
+ const timestamp = timestampMatch ? Number.parseInt(timestampMatch[1]) : 0;
412
+ return {
413
+ timestamp,
414
+ file,
415
+ created: "",
416
+ // Dosya içeriğinden çıkarılabilir ancak performans için boş bırakıldı
417
+ isPatch
418
+ };
419
+ }).sort((a, b) => a.timestamp - b.timestamp);
420
+ } catch (error) {
421
+ console.error(`Migration listesi al\u0131namad\u0131: ${error instanceof Error ? error.message : String(error)}`);
422
+ return [];
423
+ }
424
+ }
425
+ async function migrationUp(migrationsDir, targetTimestamp) {
426
+ try {
427
+ const migrations = await listMigrations(migrationsDir);
428
+ if (migrations.length === 0) {
429
+ return {
430
+ success: false,
431
+ status: "error" /* ERROR */,
432
+ error: "Migration bulunamad\u0131"
433
+ };
434
+ }
435
+ const targetMigrations = targetTimestamp ? migrations.filter((m) => m.timestamp <= targetTimestamp) : migrations;
436
+ if (targetMigrations.length === 0) {
437
+ return {
438
+ success: false,
439
+ status: "error" /* ERROR */,
440
+ error: "Belirtilen zaman damgas\u0131na kadar migration bulunamad\u0131"
441
+ };
442
+ }
443
+ const baseIndex = targetMigrations.findIndex((m) => !m.isPatch);
444
+ if (baseIndex === -1) {
445
+ return {
446
+ success: false,
447
+ status: "error" /* ERROR */,
448
+ error: "Tam veri migration bulunamad\u0131"
449
+ };
450
+ }
451
+ const baseMigration = await getMigration(
452
+ migrationsDir,
453
+ targetMigrations[baseIndex].file
454
+ );
455
+ if (!baseMigration.success || !baseMigration.data) {
456
+ return {
457
+ success: false,
458
+ status: "error" /* ERROR */,
459
+ error: `Temel veri al\u0131n\u0131rken hata: ${baseMigration.error || "Veri yok"}`
460
+ };
461
+ }
462
+ let currentData;
463
+ if (Array.isArray(baseMigration.data)) {
464
+ currentData = [...baseMigration.data];
465
+ } else {
466
+ try {
467
+ currentData = baseMigration.data ? JSON.parse(JSON.stringify(baseMigration.data)) : {};
468
+ } catch {
469
+ currentData = baseMigration.data;
470
+ }
471
+ }
472
+ for (let i = baseIndex + 1; i < targetMigrations.length; i++) {
473
+ if (!targetMigrations[i].isPatch) {
474
+ const fullMigration = await getMigration(
475
+ migrationsDir,
476
+ targetMigrations[i].file
477
+ );
478
+ if (fullMigration.success && fullMigration.data) {
479
+ if (Array.isArray(fullMigration.data)) {
480
+ currentData = [...fullMigration.data];
481
+ } else {
482
+ try {
483
+ currentData = JSON.parse(JSON.stringify(fullMigration.data));
484
+ } catch {
485
+ currentData = fullMigration.data;
486
+ }
487
+ }
488
+ } else {
489
+ console.warn(`Tam veri migration okunamad\u0131: ${targetMigrations[i].file}`);
490
+ }
491
+ continue;
492
+ }
493
+ const patchMigration = await getMigration(
494
+ migrationsDir,
495
+ targetMigrations[i].file
496
+ );
497
+ if (!patchMigration.success || !patchMigration.data) {
498
+ console.warn(`Patch migration okunamad\u0131: ${targetMigrations[i].file}`);
499
+ continue;
500
+ }
501
+ try {
502
+ const result = rfc6902.applyPatch(
503
+ currentData,
504
+ patchMigration.data
505
+ );
506
+ const errors = result.filter((r) => r !== null);
507
+ if (errors.length > 0) {
508
+ console.warn(`Patch uygulama uyar\u0131s\u0131 (${targetMigrations[i].file}):`, JSON.stringify(errors));
509
+ }
510
+ } catch (patchError) {
511
+ return {
512
+ success: false,
513
+ status: "error" /* ERROR */,
514
+ error: `Patch uygulama hatas\u0131 (${targetMigrations[i].file}): ${patchError instanceof Error ? patchError.message : String(patchError)}`
515
+ };
516
+ }
517
+ }
518
+ return {
519
+ success: true,
520
+ status: "success" /* SUCCESS */,
521
+ data: currentData,
522
+ timestamp: targetMigrations[targetMigrations.length - 1].timestamp
523
+ };
524
+ } catch (error) {
525
+ const errorMessage = error instanceof Error ? error.message : String(error || "Undefined error");
526
+ return {
527
+ success: false,
528
+ status: "error" /* ERROR */,
529
+ error: `Migration uygulama hatas\u0131: ${errorMessage}`
530
+ };
531
+ }
532
+ }
533
+ async function migrationDown(migrationsDir, targetTimestamp) {
534
+ try {
535
+ if (targetTimestamp === void 0) {
536
+ const migrations = await listMigrations(migrationsDir);
537
+ if (migrations.length <= 1) {
538
+ return {
539
+ success: false,
540
+ status: "error" /* ERROR */,
541
+ error: "Geri al\u0131nabilecek bir \xF6nceki migration bulunamad\u0131"
542
+ };
543
+ }
544
+ const previousMigrations = migrations.slice(0, migrations.length - 1);
545
+ targetTimestamp = previousMigrations[previousMigrations.length - 1].timestamp;
546
+ }
547
+ return await migrationUp(migrationsDir, targetTimestamp);
548
+ } catch (error) {
549
+ const errorMessage = error instanceof Error ? error.message : String(error || "Undefined error");
550
+ return {
551
+ success: false,
552
+ status: "error" /* ERROR */,
553
+ error: `Migration geri alma hatas\u0131: ${errorMessage}`
554
+ };
555
+ }
556
+ }
557
+
241
558
  function defineSilgiModule(definition) {
242
559
  if (definition) {
243
560
  return _defineSilgiModule(definition);
@@ -605,4 +922,4 @@ function isValidIp(ip) {
605
922
  return false;
606
923
  }
607
924
 
608
- export { MODE_RE, addTemplate, baseHeaderBannerComment, createFunction, createFunctionConfigs, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, formatFunctions, genEnsureSafeVar, getAllEntries, getIpAddress, hasError, hasInstalledModule, hasSilgiModule, hash, ipAddress, isDirectory$1 as isDirectory, isH3, isNitro, isNuxt, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, writeFile };
925
+ export { MODE_RE, MigrationStatus, addTemplate, baseHeaderBannerComment, createFunction, createFunctionConfigs, createResolver, defineSilgiModule, defineSilgiPreset, directoryToURL, filterInPlace, formatFunctions, genEnsureSafeVar, generateMigration, getAllEntries, getIpAddress, getMigration, hasError, hasInstalledModule, hasSilgiModule, hash, ipAddress, isDirectory$1 as isDirectory, isH3, isNitro, isNuxt, listMigrations, migrationDown, migrationUp, normalizeTemplate, parseServices, prettyPath, processFilePath, relativeWithDot, resolveAlias, resolvePath, resolveSilgiModule, resolveSilgiPath, serviceParseModule, toArray, tryResolveModule, useLogger, useRequest, useResponse, writeFile };
@@ -814,7 +814,6 @@ interface SilgiCLIOptions extends PresetOptions {
814
814
  installPackages: Record<'dependencies' | 'devDependencies', Record<string, string>>;
815
815
  apiFul: ApifulConfig;
816
816
  database: Record<string, {
817
- adapter: Adapter<any, TablesSchema, any>;
818
817
  tables: (options: AdapterOptions) => TablesSchema;
819
818
  } & AdapterOptions>;
820
819
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "silgi",
3
3
  "type": "module",
4
- "version": "0.28.3",
4
+ "version": "0.28.5",
5
5
  "private": false,
6
6
  "sideEffects": false,
7
7
  "exports": {
@@ -95,6 +95,7 @@
95
95
  "pathe": "^2.0.3",
96
96
  "picocolors": "^1.1.1",
97
97
  "pkg-types": "^2.1.0",
98
+ "rfc6902": "^5.1.2",
98
99
  "scule": "^1.3.0",
99
100
  "semver": "^7.7.1",
100
101
  "std-env": "^3.9.0",