@liquidmetal-ai/raindrop 0.9.0 → 0.9.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.
Files changed (129) hide show
  1. package/README.md +85 -134
  2. package/bundle/chunk-2NAMGQLL.js +805 -0
  3. package/bundle/chunk-4C3ZVVH7.js +502 -0
  4. package/bundle/chunk-4RVUC2XX.js +4539 -0
  5. package/bundle/chunk-5QVCT2XX.js +380 -0
  6. package/bundle/chunk-67CBWZ7Y.js +380 -0
  7. package/bundle/chunk-7ERI6IFL.js +22452 -0
  8. package/bundle/chunk-CZCDV5DC.js +147 -0
  9. package/bundle/chunk-D5TOYPUE.js +12148 -0
  10. package/bundle/chunk-DIDBQB37.js +12148 -0
  11. package/bundle/chunk-DV2VD4JX.js +44 -0
  12. package/bundle/chunk-FQ3UM2WC.js +4480 -0
  13. package/bundle/chunk-FTG32FZ4.js +44 -0
  14. package/bundle/chunk-GCLJVMUS.js +4539 -0
  15. package/bundle/chunk-GDYEPR67.js +75 -0
  16. package/bundle/chunk-HBDFBL3W.js +133 -0
  17. package/bundle/chunk-IMQTVYRB.js +502 -0
  18. package/bundle/chunk-IXNEFD7W.js +133 -0
  19. package/bundle/chunk-JDMAG4KE.js +147 -0
  20. package/bundle/chunk-JXNZYHAI.js +238750 -0
  21. package/bundle/chunk-OMXHWEID.js +75 -0
  22. package/bundle/chunk-ORPX7FPP.js +4484 -0
  23. package/bundle/chunk-QKHN66ZN.js +805 -0
  24. package/bundle/chunk-SP4Q3T7T.js +48 -0
  25. package/bundle/chunk-UA3E47QH.js +231 -0
  26. package/bundle/chunk-UL64FJVV.js +22452 -0
  27. package/bundle/chunk-VEVVJAL6.js +238722 -0
  28. package/bundle/chunk-Z2AQLL53.js +292 -0
  29. package/bundle/chunk-ZHLA64FP.js +48 -0
  30. package/bundle/chunk-ZHYJWVIA.js +292 -0
  31. package/bundle/chunk-ZLRYUJ5P.js +231 -0
  32. package/bundle/commands/annotation/get.js +3 -3
  33. package/bundle/commands/annotation/list.js +3 -3
  34. package/bundle/commands/annotation/put.js +3 -3
  35. package/bundle/commands/auth/list.js +2 -2
  36. package/bundle/commands/auth/login.js +3 -3
  37. package/bundle/commands/auth/logout.js +2 -2
  38. package/bundle/commands/auth/select.js +3 -3
  39. package/bundle/commands/bucket/create-credential.js +2 -2
  40. package/bundle/commands/bucket/delete-credential.js +2 -2
  41. package/bundle/commands/bucket/get-credential.js +2 -2
  42. package/bundle/commands/bucket/list-credentials.js +2 -2
  43. package/bundle/commands/build/branch.js +9 -9
  44. package/bundle/commands/build/checkout.js +5 -5
  45. package/bundle/commands/build/clone.js +5 -5
  46. package/bundle/commands/build/delete.js +5 -5
  47. package/bundle/commands/build/deploy.js +9 -9
  48. package/bundle/commands/build/env/get.js +2 -2
  49. package/bundle/commands/build/env/set.js +2 -2
  50. package/bundle/commands/build/find.js +3 -3
  51. package/bundle/commands/build/generate.js +3 -3
  52. package/bundle/commands/build/init.js +3 -3
  53. package/bundle/commands/build/list.js +4 -4
  54. package/bundle/commands/build/sandbox.js +7 -7
  55. package/bundle/commands/build/start.js +2 -2
  56. package/bundle/commands/build/status.js +4 -4
  57. package/bundle/commands/build/stop.js +2 -2
  58. package/bundle/commands/build/tools/check.js +2 -2
  59. package/bundle/commands/build/tools/fmt.js +2 -2
  60. package/bundle/commands/build/unsandbox.js +7 -7
  61. package/bundle/commands/build/upload.js +5 -5
  62. package/bundle/commands/build/validate.js +4 -4
  63. package/bundle/commands/build/workos/delete.js +4 -4
  64. package/bundle/commands/build/workos/env/attach.js +3 -3
  65. package/bundle/commands/build/workos/env/create.js +3 -3
  66. package/bundle/commands/build/workos/env/delete.js +3 -3
  67. package/bundle/commands/build/workos/env/detach.js +3 -3
  68. package/bundle/commands/build/workos/env/get.js +3 -3
  69. package/bundle/commands/build/workos/env/list.js +3 -3
  70. package/bundle/commands/build/workos/env/set.js +3 -3
  71. package/bundle/commands/build/workos/invite.js +3 -3
  72. package/bundle/commands/build/workos/setup.js +3 -3
  73. package/bundle/commands/build/workos/status.js +3 -3
  74. package/bundle/commands/dns/create.js +2 -2
  75. package/bundle/commands/dns/delete.js +4 -4
  76. package/bundle/commands/dns/get.js +4 -4
  77. package/bundle/commands/dns/list.js +3 -3
  78. package/bundle/commands/dns/records/create.js +2 -2
  79. package/bundle/commands/dns/records/delete.js +3 -3
  80. package/bundle/commands/dns/records/get.js +2 -2
  81. package/bundle/commands/dns/records/list.js +2 -2
  82. package/bundle/commands/dns/records/update.js +2 -2
  83. package/bundle/commands/logs/query.js +3 -3
  84. package/bundle/commands/logs/tail.js +3 -3
  85. package/bundle/commands/mcp/install-claude.js +2 -2
  86. package/bundle/commands/mcp/install-gemini.js +2 -2
  87. package/bundle/commands/mcp/install-goose.js +2 -2
  88. package/bundle/commands/mcp/status.js +2 -2
  89. package/bundle/commands/object/delete.js +2 -2
  90. package/bundle/commands/object/get.js +2 -2
  91. package/bundle/commands/object/list.js +2 -2
  92. package/bundle/commands/object/put.js +2 -2
  93. package/bundle/commands/query/chunk-search.js +3 -3
  94. package/bundle/commands/query/document.js +3 -3
  95. package/bundle/commands/query/events.js +2 -2
  96. package/bundle/commands/query/reindex.js +2 -2
  97. package/bundle/commands/query/search.js +3 -3
  98. package/bundle/commands/tail.js +2 -2
  99. package/bundle/index.js +1 -1
  100. package/dist/base-command.d.ts +4 -4
  101. package/dist/base-command.d.ts.map +1 -1
  102. package/dist/base-command.js +2 -2
  103. package/dist/commands/{build/package-template.d.ts → killswitch.d.ts} +7 -15
  104. package/dist/commands/killswitch.d.ts.map +1 -0
  105. package/dist/commands/killswitch.js +58 -0
  106. package/dist/index.d.ts +5 -5
  107. package/dist/index.d.ts.map +1 -1
  108. package/dist/index.js +5 -5
  109. package/dist/utils/mixpanel.d.ts +10 -0
  110. package/dist/utils/mixpanel.d.ts.map +1 -0
  111. package/dist/utils/mixpanel.js +43 -0
  112. package/oclif.manifest.json +1920 -2187
  113. package/package.json +3 -3
  114. package/templates/db/node_modules/.bin/prisma +2 -2
  115. package/templates/db/node_modules/.bin/prisma-kysely +2 -2
  116. package/templates/db/node_modules/.bin/tsc +2 -2
  117. package/templates/db/node_modules/.bin/tsserver +2 -2
  118. package/templates/db/node_modules/.bin/zx +2 -2
  119. package/bundle/chunk-6CDCK5IP.js +0 -58
  120. package/bundle/commands/build/list-templates.js +0 -63
  121. package/bundle/commands/build/package-template.js +0 -238
  122. package/dist/commands/build/list-templates.d.ts +0 -11
  123. package/dist/commands/build/list-templates.d.ts.map +0 -1
  124. package/dist/commands/build/list-templates.js +0 -47
  125. package/dist/commands/build/package-template.d.ts.map +0 -1
  126. package/dist/commands/build/package-template.js +0 -256
  127. package/dist/templates/registry.d.ts +0 -38
  128. package/dist/templates/registry.d.ts.map +0 -1
  129. package/dist/templates/registry.js +0 -72
@@ -0,0 +1,147 @@
1
+ import {
2
+ source_default
3
+ } from "./chunk-4C3ZVVH7.js";
4
+ import {
5
+ UnitState,
6
+ init_cjs_shims,
7
+ valueOf
8
+ } from "./chunk-VEVVJAL6.js";
9
+
10
+ // src/status.ts
11
+ init_cjs_shims();
12
+ import * as readline from "readline";
13
+ var statusString = {
14
+ [UnitState.UNSPECIFIED]: "<unknown>",
15
+ [UnitState.PENDING]: "pending...",
16
+ [UnitState.STARTING]: "starting...",
17
+ [UnitState.RUNNING]: "running",
18
+ [UnitState.STOPPING]: "stopping...",
19
+ [UnitState.STOPPED]: "stopped",
20
+ [UnitState.DELETING]: "deleting...",
21
+ [UnitState.DELETED]: "deleted"
22
+ };
23
+ async function getStatus(options) {
24
+ const { command, impersonate } = options;
25
+ let applicationName = options.applicationName;
26
+ let versionId = options.versionId;
27
+ if (!versionId) {
28
+ const config = await command.loadConfig();
29
+ versionId = config.versionId;
30
+ }
31
+ if (!applicationName) {
32
+ const apps = await command.loadManifest();
33
+ const app = apps[0];
34
+ if (app === void 0) {
35
+ command.error("No application provided or found in manifest");
36
+ }
37
+ applicationName = valueOf(app.name);
38
+ }
39
+ const { client: catalogService, userId, organizationId: defaultOrganizationId } = await command.catalogService();
40
+ const organizationId = impersonate ?? defaultOrganizationId;
41
+ const status = await catalogService.status({
42
+ userId,
43
+ organizationId,
44
+ applicationName,
45
+ currentVersionId: versionId || ""
46
+ });
47
+ if (status === void 0) {
48
+ command.error(`Application ${applicationName} not found`);
49
+ }
50
+ return status;
51
+ }
52
+ async function watchStatus(options) {
53
+ const { command } = options;
54
+ const renderer = new StatusRenderer();
55
+ let applicationName = options.applicationName;
56
+ let versionId = options.versionId;
57
+ if (!applicationName) {
58
+ const apps = await command.loadManifest();
59
+ const app = apps[0];
60
+ if (app) {
61
+ applicationName = valueOf(app.name);
62
+ }
63
+ }
64
+ if (!versionId) {
65
+ const config = await command.loadConfig();
66
+ versionId = config.versionId;
67
+ }
68
+ let status = await getStatus(options);
69
+ while (true) {
70
+ renderer.renderLive(status, applicationName, versionId);
71
+ if (status.state === UnitState.RUNNING || status.state === UnitState.STOPPED) {
72
+ break;
73
+ }
74
+ await new Promise((resolve) => setTimeout(resolve, 1e3));
75
+ status = await getStatus(options);
76
+ }
77
+ }
78
+ var StatusRenderer = class {
79
+ linesLastRendered = 0;
80
+ getStatusColor(state) {
81
+ switch (state) {
82
+ case UnitState.RUNNING:
83
+ return source_default.green;
84
+ case UnitState.PENDING:
85
+ case UnitState.STARTING:
86
+ return source_default.yellow;
87
+ case UnitState.STOPPING:
88
+ case UnitState.DELETING:
89
+ return source_default.yellow;
90
+ case UnitState.STOPPED:
91
+ case UnitState.DELETED:
92
+ return source_default.red;
93
+ default:
94
+ return source_default.gray;
95
+ }
96
+ }
97
+ renderLive(status, applicationName, versionId) {
98
+ if (this.linesLastRendered > 0) {
99
+ readline.moveCursor(process.stdout, 0, -this.linesLastRendered);
100
+ readline.clearScreenDown(process.stdout);
101
+ }
102
+ const lines = [];
103
+ lines.push("");
104
+ lines.push(`${source_default.bold(applicationName)} ${source_default.dim(versionId ? `@${versionId.substring(0, 8)}...` : "")}`);
105
+ lines.push(source_default.dim(`Status: ${this.getStatusColor(status.state)(statusString[status.state])}`));
106
+ lines.push("");
107
+ lines.push(`${source_default.bold("Modules")} ${source_default.dim(`(${status.modules.length})`)}`);
108
+ for (const module of status.modules) {
109
+ const statusColor = this.getStatusColor(module.state);
110
+ const notification = module.notification ? ` - ${source_default.cyan(module.notification)}` : "";
111
+ lines.push(` \u2514\u2500 ${source_default.yellow(module.name)} - ${statusColor(statusString[module.state])}${notification}`);
112
+ }
113
+ const runningModules = status.modules.filter((m) => m.state === UnitState.RUNNING).length;
114
+ const totalModules = status.modules.length;
115
+ lines.push("");
116
+ lines.push(source_default.dim("\u2500".repeat(50)));
117
+ lines.push(source_default.dim(`Total: ${totalModules} modules (${runningModules} running)`));
118
+ for (const line of lines) {
119
+ console.log(line);
120
+ }
121
+ this.linesLastRendered = lines.length;
122
+ }
123
+ renderCompact(status, applicationName, versionId) {
124
+ console.log(`
125
+ ${source_default.bold(applicationName)} ${source_default.dim(versionId ? `@${versionId.substring(0, 8)}...` : "")}`);
126
+ console.log(source_default.dim(`Status: ${this.getStatusColor(status.state)(statusString[status.state])}`));
127
+ console.log(`
128
+ ${source_default.bold("Modules")} ${source_default.dim(`(${status.modules.length})`)}`);
129
+ for (const module of status.modules) {
130
+ const statusColor = this.getStatusColor(module.state);
131
+ const notification = module.notification ? ` - ${source_default.cyan(module.notification)}` : "";
132
+ console.log(` \u2514\u2500 ${source_default.yellow(module.name)} - ${statusColor(statusString[module.state])}${notification}`);
133
+ }
134
+ const runningModules = status.modules.filter((m) => m.state === UnitState.RUNNING).length;
135
+ const totalModules = status.modules.length;
136
+ console.log("");
137
+ console.log(source_default.dim("\u2500".repeat(50)));
138
+ console.log(source_default.dim(`Total: ${totalModules} modules (${runningModules} running)`));
139
+ }
140
+ };
141
+
142
+ export {
143
+ statusString,
144
+ getStatus,
145
+ watchStatus,
146
+ StatusRenderer
147
+ };