@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
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@liquidmetal-ai/raindrop",
3
3
  "description": "CLI for the Raindrop platform",
4
- "version": "0.9.0",
4
+ "version": "0.9.1",
5
5
  "author": "bosgood",
6
6
  "bin": {
7
7
  "raindrop": "./bin/run.js"
@@ -36,8 +36,8 @@
36
36
  "typescript": "^5",
37
37
  "zod": "^3.23.8",
38
38
  "zx": "^8.1.9",
39
- "@liquidmetal-ai/raindrop-framework": "0.9.0",
40
- "@liquidmetal-ai/drizzle": "0.9.0"
39
+ "@liquidmetal-ai/drizzle": "0.9.1",
40
+ "@liquidmetal-ai/raindrop-framework": "0.9.1"
41
41
  },
42
42
  "devDependencies": {
43
43
  "@changesets/cli": "^2.27.9",
@@ -6,9 +6,9 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/build/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/build/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/build/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/build/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
14
  exec "$basedir/node" "$basedir/../../../../../../node_modules/.pnpm/prisma@6.10.1_typescript@5.9.2/node_modules/prisma/build/index.js" "$@"
@@ -6,9 +6,9 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/dist/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/dist/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/dist/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/dist/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/prisma-kysely@1.8.0/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
14
  exec "$basedir/node" "$basedir/../../../../../../node_modules/.pnpm/prisma-kysely@1.8.0/node_modules/prisma-kysely/dist/bin.js" "$@"
@@ -6,9 +6,9 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
14
  exec "$basedir/node" "$basedir/../../../../../../node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/tsc" "$@"
@@ -6,9 +6,9 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/typescript@5.9.2/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
14
  exec "$basedir/node" "$basedir/../../../../../../node_modules/.pnpm/typescript@5.9.2/node_modules/typescript/bin/tsserver" "$@"
@@ -6,9 +6,9 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/build/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/build/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/Users/matt/Development/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/build/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules:/Users/matt/Development/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/build/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules/zx/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/zx@8.6.0/node_modules:/Users/dstaley/Work/liquidmetal/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
14
  exec "$basedir/node" "$basedir/../../../../../../node_modules/.pnpm/zx@8.6.0/node_modules/zx/build/cli.js" "$@"
@@ -1,58 +0,0 @@
1
- import {
2
- init_cjs_shims
3
- } from "./chunk-G6NE675D.js";
4
-
5
- // src/templates/registry.ts
6
- init_cjs_shims();
7
- var GITHUB_DEMOS_REPO = "https://github.com/LiquidMetal-AI/lm-raindrop-demos.git";
8
- var TEMPLATE_REGISTRY = [
9
- {
10
- id: "liquidmetal/smartbucket",
11
- name: "SmartBucket",
12
- description: "Initialize a new Raindrop project with SmartBucket and service components from scratch",
13
- type: "init"
14
- },
15
- {
16
- id: "liquidmetal/agent-template",
17
- name: "Agent Template",
18
- description: "A foundational template for building agents on the LiquidMetal platform",
19
- type: "clone",
20
- githubPath: "agent-template",
21
- githubRepo: GITHUB_DEMOS_REPO
22
- },
23
- {
24
- id: "liquidmetal/git-haiku-demo",
25
- name: "Git Haiku Demo",
26
- description: "A demonstration application showcasing git integration capabilities",
27
- type: "clone",
28
- githubPath: "git-haiku-demo",
29
- githubRepo: GITHUB_DEMOS_REPO
30
- },
31
- {
32
- id: "liquidmetal/hello-world",
33
- name: "Hello World",
34
- description: "An introductory example for getting started with the platform",
35
- type: "clone",
36
- githubPath: "hello-world",
37
- githubRepo: GITHUB_DEMOS_REPO
38
- },
39
- {
40
- id: "liquidmetal/voice-agent-demo",
41
- name: "Voice Agent Demo",
42
- description: "A sample application demonstrating voice-based agent functionality",
43
- type: "clone",
44
- githubPath: "voice-agent-demo",
45
- githubRepo: GITHUB_DEMOS_REPO
46
- }
47
- ];
48
- function getTemplateById(id) {
49
- return TEMPLATE_REGISTRY.find((template) => template.id === id);
50
- }
51
- function listTemplates() {
52
- return TEMPLATE_REGISTRY;
53
- }
54
-
55
- export {
56
- getTemplateById,
57
- listTemplates
58
- };
@@ -1,63 +0,0 @@
1
- import {
2
- listTemplates
3
- } from "../../chunk-6CDCK5IP.js";
4
- import {
5
- source_default
6
- } from "../../chunk-MVQYQJHI.js";
7
- import {
8
- BaseCommand
9
- } from "../../chunk-MCRKUPJY.js";
10
- import {
11
- __toESM,
12
- init_cjs_shims,
13
- require_lib
14
- } from "../../chunk-G6NE675D.js";
15
-
16
- // src/commands/build/list-templates.ts
17
- init_cjs_shims();
18
- var import_core = __toESM(require_lib(), 1);
19
- var ListTemplates = class extends BaseCommand {
20
- static args = {};
21
- static description = "list available Raindrop templates";
22
- static examples = [
23
- `<%= config.bin %> <%= command.id %>
24
- List all available templates in text format.
25
- `,
26
- `<%= config.bin %> <%= command.id %> -o json
27
- List templates in JSON format.
28
- `
29
- ];
30
- static flags = {
31
- output: import_core.Flags.string({
32
- char: "o",
33
- description: "output format",
34
- default: "text",
35
- options: ["text", "json"]
36
- })
37
- };
38
- async run() {
39
- const templates = listTemplates();
40
- if (this.flags.output === "json") {
41
- console.log(JSON.stringify(templates, null, 2));
42
- return;
43
- }
44
- this.log(source_default.bold.underline("\nAvailable Raindrop Templates\n"));
45
- for (const template of templates) {
46
- this.log(source_default.bold.cyan(`${template.id}`));
47
- this.log(` ${source_default.bold("Name:")} ${template.name}`);
48
- this.log(` ${source_default.bold("Type:")} ${template.type}`);
49
- this.log(` ${source_default.bold("Description:")} ${template.description}`);
50
- if (template.type === "clone" && template.githubPath) {
51
- this.log(` ${source_default.dim(`Source: ${template.githubPath}`)}`);
52
- }
53
- this.log("");
54
- }
55
- this.log(source_default.dim(`Total: ${templates.length} template${templates.length !== 1 ? "s" : ""}`));
56
- this.log(source_default.dim("\nTo clone a template, run:"));
57
- this.log(source_default.dim(" raindrop build clone <template-id> <directory>"));
58
- this.log("");
59
- }
60
- };
61
- export {
62
- ListTemplates as default
63
- };
@@ -1,238 +0,0 @@
1
- import {
2
- BaseCommand
3
- } from "../../chunk-MCRKUPJY.js";
4
- import {
5
- __toESM,
6
- init_cjs_shims,
7
- require_lib
8
- } from "../../chunk-G6NE675D.js";
9
-
10
- // src/commands/build/package-template.ts
11
- init_cjs_shims();
12
- var import_core = __toESM(require_lib(), 1);
13
- import * as fs from "node:fs/promises";
14
- import * as path from "node:path";
15
- import os from "node:os";
16
- var PackageTemplate = class extends BaseCommand {
17
- static args = {
18
- "app-name": import_core.Args.string({ description: "Name for the template application (kebab-case)", required: true }),
19
- description: import_core.Args.string({ description: "Description of the template", required: true }),
20
- path: import_core.Args.string({ description: "Destination path for the template", required: true })
21
- };
22
- static description = "Package the current raindrop project as a template";
23
- static examples = [
24
- '<%= config.bin %> <%= command.id %> my-app "A sample application" ./templates'
25
- ];
26
- static flags = {
27
- ...BaseCommand.HIDDEN_FLAGS
28
- };
29
- async run() {
30
- const { "app-name": appName, description, path: destPath } = this.args;
31
- if (!/^[a-z0-9]+(-[a-z0-9]+)*$/.test(appName)) {
32
- this.error("App name must be in kebab-case format (e.g., my-app-name)", { exit: 1 });
33
- }
34
- const projectRoot = process.cwd();
35
- const destDir = path.resolve(destPath, appName);
36
- try {
37
- await fs.access(destDir);
38
- this.warn(`Directory ${destDir} already exists. It will be overwritten.`);
39
- } catch {
40
- }
41
- await fs.mkdir(destDir, { recursive: true });
42
- this.log(`Packaging template from ${projectRoot} to ${destDir}...`);
43
- await this.copyProjectFiles(projectRoot, destDir);
44
- await this.updatePackageJson(destDir, appName);
45
- await this.updateManifest(destDir, appName);
46
- await this.copyRaindropDocs(destDir);
47
- await this.removeGitInfo(destDir);
48
- await this.createDocsReadme(destDir, appName, description);
49
- await this.createGitignore(destDir);
50
- this.log(`
51
- Template packaged successfully at ${destDir}`);
52
- }
53
- async copyProjectFiles(source, dest) {
54
- const excludeDirs = ["node_modules", "dist", "build", ".git"];
55
- const excludeFiles = [".env", ".env.local", ".env.production", "secrets.json"];
56
- const copyRecursive = async (src, dst) => {
57
- const entries = await fs.readdir(src, { withFileTypes: true });
58
- for (const entry of entries) {
59
- const srcPath = path.join(src, entry.name);
60
- const dstPath = path.join(dst, entry.name);
61
- if (entry.isDirectory()) {
62
- if (excludeDirs.includes(entry.name)) {
63
- continue;
64
- }
65
- await fs.mkdir(dstPath, { recursive: true });
66
- await copyRecursive(srcPath, dstPath);
67
- } else {
68
- if (excludeFiles.includes(entry.name)) {
69
- continue;
70
- }
71
- await fs.copyFile(srcPath, dstPath);
72
- }
73
- }
74
- };
75
- await copyRecursive(source, dest);
76
- }
77
- async updatePackageJson(destDir, appName) {
78
- const packageJsonPath = path.join(destDir, "package.json");
79
- try {
80
- const content = await fs.readFile(packageJsonPath, "utf-8");
81
- const packageJson = JSON.parse(content);
82
- packageJson.name = appName;
83
- await fs.writeFile(packageJsonPath, JSON.stringify(packageJson, null, 2) + "\n", "utf-8");
84
- this.log(`Updated package.json with name: ${appName}`);
85
- } catch (_error) {
86
- this.warn(`Could not update package.json: ${_error}`);
87
- }
88
- }
89
- async updateManifest(destDir, appName) {
90
- const manifestPath = path.join(destDir, "raindrop.manifest");
91
- try {
92
- const content = await fs.readFile(manifestPath, "utf-8");
93
- const updated = content.replace(/^application\s+"[^"]+"\s*{/m, `application "${appName}" {`);
94
- await fs.writeFile(manifestPath, updated, "utf-8");
95
- this.log(`Updated raindrop.manifest with application: ${appName}`);
96
- } catch (_error) {
97
- this.warn(`Could not update raindrop.manifest: ${_error}`);
98
- }
99
- }
100
- async copyRaindropDocs(destDir) {
101
- const raindropDir = path.join(os.homedir(), ".raindrop");
102
- const indexPath = path.join(raindropDir, "index.json");
103
- try {
104
- const manifestPath = path.join(process.cwd(), "raindrop.manifest");
105
- const manifestContent = await fs.readFile(manifestPath, "utf-8");
106
- const appNameMatch = manifestContent.match(/^application\s+"([^"]+)"\s*{/m);
107
- if (!appNameMatch) {
108
- this.warn("Could not parse application name from raindrop.manifest");
109
- await fs.mkdir(path.join(destDir, "docs"), { recursive: true });
110
- return;
111
- }
112
- const currentAppName = appNameMatch[1];
113
- const indexContent = await fs.readFile(indexPath, "utf-8");
114
- const index = JSON.parse(indexContent);
115
- let sessionId = null;
116
- if (index.applications && index.applications[currentAppName]) {
117
- sessionId = index.applications[currentAppName].latest_session_id;
118
- }
119
- if (!sessionId) {
120
- this.warn(`Could not find raindrop session for application: ${currentAppName}`);
121
- await fs.mkdir(path.join(destDir, "docs"), { recursive: true });
122
- return;
123
- }
124
- const appDocsDir = path.join(raindropDir, sessionId);
125
- try {
126
- await fs.access(appDocsDir);
127
- } catch {
128
- this.warn(`Raindrop docs directory not found: ${appDocsDir}`);
129
- await fs.mkdir(path.join(destDir, "docs"), { recursive: true });
130
- return;
131
- }
132
- const destDocsDir = path.join(destDir, "docs");
133
- await fs.mkdir(destDocsDir, { recursive: true });
134
- const entries = await fs.readdir(appDocsDir, { withFileTypes: true });
135
- for (const entry of entries) {
136
- const srcPath = path.join(appDocsDir, entry.name);
137
- const dstPath = path.join(destDocsDir, entry.name);
138
- if (entry.isDirectory()) {
139
- await fs.mkdir(dstPath, { recursive: true });
140
- const copyDir = async (src, dst) => {
141
- const subEntries = await fs.readdir(src, { withFileTypes: true });
142
- for (const subEntry of subEntries) {
143
- const subSrc = path.join(src, subEntry.name);
144
- const subDst = path.join(dst, subEntry.name);
145
- if (subEntry.isDirectory()) {
146
- await fs.mkdir(subDst, { recursive: true });
147
- await copyDir(subSrc, subDst);
148
- } else {
149
- await fs.copyFile(subSrc, subDst);
150
- }
151
- }
152
- };
153
- await copyDir(srcPath, dstPath);
154
- } else {
155
- await fs.copyFile(srcPath, dstPath);
156
- }
157
- }
158
- this.log(`Copied raindrop docs from ${appDocsDir}`);
159
- } catch (_error) {
160
- this.warn(`Could not copy raindrop docs: ${_error}`);
161
- await fs.mkdir(path.join(destDir, "docs"), { recursive: true });
162
- }
163
- }
164
- async removeGitInfo(destDir) {
165
- const gitDir = path.join(destDir, ".git");
166
- try {
167
- await fs.rm(gitDir, { recursive: true, force: true });
168
- this.log("Removed .git directory");
169
- } catch {
170
- }
171
- }
172
- async createDocsReadme(destDir, appName, description) {
173
- const docsDir = path.join(destDir, "docs");
174
- const readmePath = path.join(docsDir, "README.md");
175
- const readmeContent = `# ${appName}
176
-
177
- ## Description
178
-
179
- ${description}
180
-
181
- ## Usage
182
-
183
- Instructions for using this template will be added here.
184
- `;
185
- await fs.writeFile(readmePath, readmeContent, "utf-8");
186
- this.log("Created docs/README.md");
187
- }
188
- async createGitignore(destDir) {
189
- const gitignorePath = path.join(destDir, ".gitignore");
190
- const gitignoreContent = `# Dependencies
191
- node_modules/
192
- .pnpm-store/
193
-
194
- # Build outputs
195
- dist/
196
- build/
197
- *.tsbuildinfo
198
-
199
- # Environment variables
200
- .env
201
- .env.local
202
- .env.production
203
- .env.*.local
204
-
205
- # Secrets
206
- secrets.json
207
- *.key
208
- *.pem
209
-
210
- # IDE
211
- .vscode/
212
- .idea/
213
- *.swp
214
- *.swo
215
- *~
216
-
217
- # OS
218
- .DS_Store
219
- Thumbs.db
220
-
221
- # Logs
222
- *.log
223
- logs/
224
-
225
- # Testing
226
- coverage/
227
- .nyc_output/
228
-
229
- # Raindrop local config
230
- .raindrop/
231
- `;
232
- await fs.writeFile(gitignorePath, gitignoreContent, "utf-8");
233
- this.log("Created .gitignore");
234
- }
235
- };
236
- export {
237
- PackageTemplate as default
238
- };
@@ -1,11 +0,0 @@
1
- import { BaseCommand } from '../../base-command.js';
2
- export default class ListTemplates extends BaseCommand<typeof ListTemplates> {
3
- static args: {};
4
- static description: string;
5
- static examples: string[];
6
- static flags: {
7
- output: import("@oclif/core/interfaces").OptionFlag<string, import("@oclif/core/interfaces").CustomOptions>;
8
- };
9
- run(): Promise<void>;
10
- }
11
- //# sourceMappingURL=list-templates.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"list-templates.d.ts","sourceRoot":"","sources":["../../../src/commands/build/list-templates.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGpD,MAAM,CAAC,OAAO,OAAO,aAAc,SAAQ,WAAW,CAAC,OAAO,aAAa,CAAC;IAC1E,MAAM,CAAC,IAAI,KAAM;IAEjB,MAAM,CAAC,WAAW,SAAuC;IAEzD,MAAM,CAAC,QAAQ,WAOb;IAEF,MAAM,CAAC,KAAK;;MAOV;IAEI,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;CA6B3B"}
@@ -1,47 +0,0 @@
1
- import { Flags } from '@oclif/core';
2
- import chalk from 'chalk';
3
- import { BaseCommand } from '../../base-command.js';
4
- import { listTemplates } from '../../templates/registry.js';
5
- export default class ListTemplates extends BaseCommand {
6
- static args = {};
7
- static description = 'list available Raindrop templates';
8
- static examples = [
9
- `<%= config.bin %> <%= command.id %>
10
- List all available templates in text format.
11
- `,
12
- `<%= config.bin %> <%= command.id %> -o json
13
- List templates in JSON format.
14
- `,
15
- ];
16
- static flags = {
17
- output: Flags.string({
18
- char: 'o',
19
- description: 'output format',
20
- default: 'text',
21
- options: ['text', 'json'],
22
- }),
23
- };
24
- async run() {
25
- const templates = listTemplates();
26
- if (this.flags.output === 'json') {
27
- console.log(JSON.stringify(templates, null, 2));
28
- return;
29
- }
30
- // Text output
31
- this.log(chalk.bold.underline('\nAvailable Raindrop Templates\n'));
32
- for (const template of templates) {
33
- this.log(chalk.bold.cyan(`${template.id}`));
34
- this.log(` ${chalk.bold('Name:')} ${template.name}`);
35
- this.log(` ${chalk.bold('Type:')} ${template.type}`);
36
- this.log(` ${chalk.bold('Description:')} ${template.description}`);
37
- if (template.type === 'clone' && template.githubPath) {
38
- this.log(` ${chalk.dim(`Source: ${template.githubPath}`)}`);
39
- }
40
- this.log('');
41
- }
42
- this.log(chalk.dim(`Total: ${templates.length} template${templates.length !== 1 ? 's' : ''}`));
43
- this.log(chalk.dim('\nTo clone a template, run:'));
44
- this.log(chalk.dim(' raindrop build clone <template-id> <directory>'));
45
- this.log('');
46
- }
47
- }
@@ -1 +0,0 @@
1
- {"version":3,"file":"package-template.d.ts","sourceRoot":"","sources":["../../../src/commands/build/package-template.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AAGpD,MAAM,CAAC,OAAO,OAAO,eAAgB,SAAQ,WAAW,CAAC,OAAO,eAAe,CAAC;IAC9E,OAAgB,IAAI;;;;MAIlB;IAEF,OAAgB,WAAW,SAAwD;IAEnF,OAAgB,QAAQ,WAEtB;IAEF,OAAgB,KAAK;;;;;;;;MAEnB;IAEI,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC;YAmDZ,gBAAgB;YA6BhB,iBAAiB;YAajB,cAAc;YAad,gBAAgB;YAqFhB,aAAa;YAUb,gBAAgB;YAmBhB,eAAe;CAiD9B"}