opencode-hive 0.8.0 → 0.8.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 (48) hide show
  1. package/dist/index.js +19251 -587
  2. package/package.json +4 -3
  3. package/dist/e2e/opencode-runtime-smoke.test.d.ts +0 -1
  4. package/dist/e2e/opencode-runtime-smoke.test.js +0 -243
  5. package/dist/e2e/plugin-smoke.test.d.ts +0 -1
  6. package/dist/e2e/plugin-smoke.test.js +0 -127
  7. package/dist/services/contextService.d.ts +0 -15
  8. package/dist/services/contextService.js +0 -59
  9. package/dist/services/featureService.d.ts +0 -14
  10. package/dist/services/featureService.js +0 -107
  11. package/dist/services/featureService.test.d.ts +0 -1
  12. package/dist/services/featureService.test.js +0 -127
  13. package/dist/services/index.d.ts +0 -5
  14. package/dist/services/index.js +0 -4
  15. package/dist/services/planService.d.ts +0 -11
  16. package/dist/services/planService.js +0 -59
  17. package/dist/services/planService.test.d.ts +0 -1
  18. package/dist/services/planService.test.js +0 -115
  19. package/dist/services/sessionService.d.ts +0 -31
  20. package/dist/services/sessionService.js +0 -125
  21. package/dist/services/taskService.d.ts +0 -29
  22. package/dist/services/taskService.js +0 -382
  23. package/dist/services/taskService.test.d.ts +0 -1
  24. package/dist/services/taskService.test.js +0 -290
  25. package/dist/services/worktreeService.d.ts +0 -66
  26. package/dist/services/worktreeService.js +0 -498
  27. package/dist/services/worktreeService.test.d.ts +0 -1
  28. package/dist/services/worktreeService.test.js +0 -185
  29. package/dist/tools/contextTools.d.ts +0 -93
  30. package/dist/tools/contextTools.js +0 -83
  31. package/dist/tools/execTools.d.ts +0 -66
  32. package/dist/tools/execTools.js +0 -125
  33. package/dist/tools/featureTools.d.ts +0 -60
  34. package/dist/tools/featureTools.js +0 -73
  35. package/dist/tools/planTools.d.ts +0 -47
  36. package/dist/tools/planTools.js +0 -65
  37. package/dist/tools/sessionTools.d.ts +0 -35
  38. package/dist/tools/sessionTools.js +0 -95
  39. package/dist/tools/taskTools.d.ts +0 -79
  40. package/dist/tools/taskTools.js +0 -86
  41. package/dist/types.d.ts +0 -106
  42. package/dist/types.js +0 -1
  43. package/dist/utils/detection.d.ts +0 -12
  44. package/dist/utils/detection.js +0 -73
  45. package/dist/utils/paths.d.ts +0 -23
  46. package/dist/utils/paths.js +0 -92
  47. package/dist/utils/paths.test.d.ts +0 -1
  48. package/dist/utils/paths.test.js +0 -100
@@ -1,185 +0,0 @@
1
- import { describe, it, expect, beforeEach, afterEach } from "bun:test";
2
- import * as fs from "fs";
3
- import * as path from "path";
4
- import { WorktreeService } from "./worktreeService";
5
- const TEST_ROOT = "/tmp/hive-test-worktree";
6
- describe("WorktreeService", () => {
7
- let service;
8
- beforeEach(async () => {
9
- fs.rmSync(TEST_ROOT, { recursive: true, force: true });
10
- fs.mkdirSync(TEST_ROOT, { recursive: true });
11
- const { execSync } = await import("child_process");
12
- execSync("git init", { cwd: TEST_ROOT });
13
- execSync("git config user.email 'test@test.com'", { cwd: TEST_ROOT });
14
- execSync("git config user.name 'Test'", { cwd: TEST_ROOT });
15
- fs.writeFileSync(path.join(TEST_ROOT, "README.md"), "# Test");
16
- execSync("git add . && git commit -m 'init'", { cwd: TEST_ROOT });
17
- service = new WorktreeService({ baseDir: TEST_ROOT, hiveDir: path.join(TEST_ROOT, ".hive") });
18
- });
19
- afterEach(() => {
20
- fs.rmSync(TEST_ROOT, { recursive: true, force: true });
21
- });
22
- describe("create", () => {
23
- it("creates a worktree", async () => {
24
- const result = await service.create("my-feature", "01-setup");
25
- expect(result.path).toContain(".hive/.worktrees/my-feature/01-setup");
26
- expect(result.branch).toBe("hive/my-feature/01-setup");
27
- expect(fs.existsSync(result.path)).toBe(true);
28
- });
29
- it("worktree contains files from base branch", async () => {
30
- const result = await service.create("my-feature", "01-setup");
31
- expect(fs.existsSync(path.join(result.path, "README.md"))).toBe(true);
32
- });
33
- });
34
- describe("get", () => {
35
- it("returns null for non-existing worktree", async () => {
36
- const result = await service.get("nope", "nope");
37
- expect(result).toBeNull();
38
- });
39
- it("returns worktree info after creation", async () => {
40
- await service.create("my-feature", "01-task");
41
- const result = await service.get("my-feature", "01-task");
42
- expect(result).not.toBeNull();
43
- expect(result.feature).toBe("my-feature");
44
- expect(result.step).toBe("01-task");
45
- });
46
- });
47
- describe("list", () => {
48
- it("returns empty array when no worktrees", async () => {
49
- const result = await service.list();
50
- expect(result).toEqual([]);
51
- });
52
- it("lists all worktrees", async () => {
53
- await service.create("feature-a", "01-task");
54
- await service.create("feature-b", "01-task");
55
- const result = await service.list();
56
- expect(result.length).toBe(2);
57
- });
58
- it("filters by feature", async () => {
59
- await service.create("feature-a", "01-task");
60
- await service.create("feature-a", "02-task");
61
- await service.create("feature-b", "01-task");
62
- const result = await service.list("feature-a");
63
- expect(result.length).toBe(2);
64
- expect(result.every(w => w.feature === "feature-a")).toBe(true);
65
- });
66
- });
67
- describe("remove", () => {
68
- it("removes worktree", async () => {
69
- const created = await service.create("my-feature", "01-task");
70
- expect(fs.existsSync(created.path)).toBe(true);
71
- await service.remove("my-feature", "01-task");
72
- expect(fs.existsSync(created.path)).toBe(false);
73
- });
74
- it("removes branch when deleteBranch is true", async () => {
75
- await service.create("my-feature", "01-task");
76
- const { execSync } = await import("child_process");
77
- await service.remove("my-feature", "01-task", true);
78
- const branches = execSync("git branch", { cwd: TEST_ROOT, encoding: "utf-8" });
79
- expect(branches).not.toContain("hive/my-feature/01-task");
80
- });
81
- });
82
- describe("getDiff", () => {
83
- it("returns empty diff when no changes", async () => {
84
- await service.create("my-feature", "01-task");
85
- const diff = await service.getDiff("my-feature", "01-task");
86
- expect(diff.hasDiff).toBe(false);
87
- expect(diff.diffContent).toBe("");
88
- expect(diff.filesChanged).toEqual([]);
89
- });
90
- it("returns diff when files changed and committed", async () => {
91
- const worktree = await service.create("my-feature", "01-task");
92
- fs.writeFileSync(path.join(worktree.path, "new-file.txt"), "content");
93
- const { execSync } = await import("child_process");
94
- execSync("git add .", { cwd: worktree.path });
95
- execSync("git commit -m 'add file'", { cwd: worktree.path });
96
- const diff = await service.getDiff("my-feature", "01-task");
97
- expect(diff.hasDiff).toBe(true);
98
- expect(diff.filesChanged).toContain("new-file.txt");
99
- });
100
- it("returns diff for uncommitted staged changes", async () => {
101
- const worktree = await service.create("my-feature", "01-task");
102
- fs.writeFileSync(path.join(worktree.path, "uncommitted.txt"), "staged content");
103
- const diff = await service.getDiff("my-feature", "01-task");
104
- expect(diff.hasDiff).toBe(true);
105
- expect(diff.filesChanged).toContain("uncommitted.txt");
106
- });
107
- });
108
- describe("commitChanges", () => {
109
- it("commits all staged changes", async () => {
110
- const worktree = await service.create("my-feature", "01-task");
111
- fs.writeFileSync(path.join(worktree.path, "file.txt"), "content");
112
- const result = await service.commitChanges("my-feature", "01-task", "test commit");
113
- expect(result.committed).toBe(true);
114
- expect(result.sha).toBeTruthy();
115
- });
116
- it("returns committed=false when no changes", async () => {
117
- await service.create("my-feature", "01-task");
118
- const result = await service.commitChanges("my-feature", "01-task");
119
- expect(result.committed).toBe(false);
120
- expect(result.message).toBe("No changes to commit");
121
- });
122
- it("returns error when worktree not found", async () => {
123
- const result = await service.commitChanges("nope", "nope");
124
- expect(result.committed).toBe(false);
125
- expect(result.message).toBe("Worktree not found");
126
- });
127
- });
128
- describe("hasUncommittedChanges", () => {
129
- it("returns false when no changes", async () => {
130
- await service.create("my-feature", "01-task");
131
- const result = await service.hasUncommittedChanges("my-feature", "01-task");
132
- expect(result).toBe(false);
133
- });
134
- it("returns true when files modified", async () => {
135
- const worktree = await service.create("my-feature", "01-task");
136
- fs.writeFileSync(path.join(worktree.path, "new.txt"), "content");
137
- const result = await service.hasUncommittedChanges("my-feature", "01-task");
138
- expect(result).toBe(true);
139
- });
140
- });
141
- describe("merge", () => {
142
- it("merges task branch into main", async () => {
143
- const worktree = await service.create("my-feature", "01-task");
144
- fs.writeFileSync(path.join(worktree.path, "feature.txt"), "feature content");
145
- const { execSync } = await import("child_process");
146
- execSync("git add . && git commit -m 'feature'", { cwd: worktree.path });
147
- const result = await service.merge("my-feature", "01-task");
148
- expect(result.success).toBe(true);
149
- expect(result.merged).toBe(true);
150
- expect(fs.existsSync(path.join(TEST_ROOT, "feature.txt"))).toBe(true);
151
- });
152
- it("returns error for non-existent branch", async () => {
153
- const result = await service.merge("nope", "nope");
154
- expect(result.success).toBe(false);
155
- expect(result.error).toContain("not found");
156
- });
157
- it("supports squash strategy", async () => {
158
- const worktree = await service.create("my-feature", "01-task");
159
- fs.writeFileSync(path.join(worktree.path, "file1.txt"), "1");
160
- const { execSync } = await import("child_process");
161
- execSync("git add . && git commit -m 'commit 1'", { cwd: worktree.path });
162
- fs.writeFileSync(path.join(worktree.path, "file2.txt"), "2");
163
- execSync("git add . && git commit -m 'commit 2'", { cwd: worktree.path });
164
- const result = await service.merge("my-feature", "01-task", "squash");
165
- expect(result.success).toBe(true);
166
- expect(result.merged).toBe(true);
167
- });
168
- });
169
- describe("cleanup", () => {
170
- it("removes invalid worktrees for a feature", async () => {
171
- const wt1 = await service.create("cleanup-test", "01-task");
172
- const wt2 = await service.create("cleanup-test", "02-task");
173
- fs.writeFileSync(path.join(wt1.path, ".git"), "gitdir: /nonexistent\n");
174
- fs.writeFileSync(path.join(wt2.path, ".git"), "gitdir: /nonexistent\n");
175
- expect(fs.existsSync(wt1.path)).toBe(true);
176
- expect(fs.existsSync(wt2.path)).toBe(true);
177
- const result = await service.cleanup("cleanup-test");
178
- expect(result.removed.length).toBe(2);
179
- expect(fs.existsSync(wt1.path)).toBe(false);
180
- expect(fs.existsSync(wt2.path)).toBe(false);
181
- const remaining = await service.list("cleanup-test");
182
- expect(remaining).toEqual([]);
183
- });
184
- });
185
- });
@@ -1,93 +0,0 @@
1
- import { z } from 'zod';
2
- export declare function createContextTools(projectRoot: string): {
3
- hive_context_write: {
4
- description: string;
5
- parameters: z.ZodObject<{
6
- name: z.ZodString;
7
- content: z.ZodString;
8
- }, z.core.$strip>;
9
- execute: ({ name, content }: {
10
- name: string;
11
- content: string;
12
- }) => Promise<{
13
- error: string;
14
- success?: undefined;
15
- path?: undefined;
16
- } | {
17
- success: boolean;
18
- path: string;
19
- error?: undefined;
20
- }>;
21
- };
22
- hive_context_read: {
23
- description: string;
24
- parameters: z.ZodObject<{
25
- name: z.ZodOptional<z.ZodString>;
26
- }, z.core.$strip>;
27
- execute: ({ name }: {
28
- name?: string;
29
- }) => Promise<{
30
- error: string;
31
- name?: undefined;
32
- content?: undefined;
33
- message?: undefined;
34
- compiled?: undefined;
35
- } | {
36
- name: string;
37
- content: string;
38
- error?: undefined;
39
- message?: undefined;
40
- compiled?: undefined;
41
- } | {
42
- message: string;
43
- error?: undefined;
44
- name?: undefined;
45
- content?: undefined;
46
- compiled?: undefined;
47
- } | {
48
- compiled: string;
49
- error?: undefined;
50
- name?: undefined;
51
- content?: undefined;
52
- message?: undefined;
53
- }>;
54
- };
55
- hive_context_list: {
56
- description: string;
57
- parameters: z.ZodObject<{}, z.core.$strip>;
58
- execute: () => Promise<{
59
- error: string;
60
- files?: undefined;
61
- message?: undefined;
62
- } | {
63
- files: never[];
64
- message: string;
65
- error?: undefined;
66
- } | {
67
- files: {
68
- name: string;
69
- updatedAt: string;
70
- previewLength: number;
71
- }[];
72
- error?: undefined;
73
- message?: undefined;
74
- }>;
75
- };
76
- hive_context_delete: {
77
- description: string;
78
- parameters: z.ZodObject<{
79
- name: z.ZodString;
80
- }, z.core.$strip>;
81
- execute: ({ name }: {
82
- name: string;
83
- }) => Promise<{
84
- error: string;
85
- success?: undefined;
86
- deleted?: undefined;
87
- } | {
88
- success: boolean;
89
- deleted: string;
90
- error?: undefined;
91
- }>;
92
- };
93
- };
@@ -1,83 +0,0 @@
1
- import { z } from 'zod';
2
- import { ContextService } from '../services/contextService.js';
3
- import { FeatureService } from '../services/featureService.js';
4
- import { detectContext } from '../utils/detection.js';
5
- export function createContextTools(projectRoot) {
6
- const contextService = new ContextService(projectRoot);
7
- const featureService = new FeatureService(projectRoot);
8
- const getActiveFeature = () => {
9
- const ctx = detectContext(projectRoot);
10
- return ctx?.feature || null;
11
- };
12
- return {
13
- hive_context_write: {
14
- description: 'Write a context file for the active feature. Context files store persistent notes, decisions, and reference material.',
15
- parameters: z.object({
16
- name: z.string().describe('Context file name (e.g., "architecture", "decisions", "notes")'),
17
- content: z.string().describe('Markdown content to write'),
18
- }),
19
- execute: async ({ name, content }) => {
20
- const feature = getActiveFeature();
21
- if (!feature)
22
- return { error: 'No active feature' };
23
- const filePath = contextService.write(feature, name, content);
24
- return { success: true, path: filePath };
25
- },
26
- },
27
- hive_context_read: {
28
- description: 'Read a specific context file or all context for the active feature',
29
- parameters: z.object({
30
- name: z.string().optional().describe('Context file name. If omitted, returns all context compiled.'),
31
- }),
32
- execute: async ({ name }) => {
33
- const feature = getActiveFeature();
34
- if (!feature)
35
- return { error: 'No active feature' };
36
- if (name) {
37
- const content = contextService.read(feature, name);
38
- if (!content)
39
- return { error: `Context file '${name}' not found` };
40
- return { name, content };
41
- }
42
- const compiled = contextService.compile(feature);
43
- if (!compiled)
44
- return { message: 'No context files found' };
45
- return { compiled };
46
- },
47
- },
48
- hive_context_list: {
49
- description: 'List all context files for the active feature',
50
- parameters: z.object({}),
51
- execute: async () => {
52
- const feature = getActiveFeature();
53
- if (!feature)
54
- return { error: 'No active feature' };
55
- const files = contextService.list(feature);
56
- if (files.length === 0)
57
- return { files: [], message: 'No context files' };
58
- return {
59
- files: files.map(f => ({
60
- name: f.name,
61
- updatedAt: f.updatedAt,
62
- previewLength: f.content.length,
63
- })),
64
- };
65
- },
66
- },
67
- hive_context_delete: {
68
- description: 'Delete a context file',
69
- parameters: z.object({
70
- name: z.string().describe('Context file name to delete'),
71
- }),
72
- execute: async ({ name }) => {
73
- const feature = getActiveFeature();
74
- if (!feature)
75
- return { error: 'No active feature' };
76
- const deleted = contextService.delete(feature, name);
77
- if (!deleted)
78
- return { error: `Context file '${name}' not found` };
79
- return { success: true, deleted: name };
80
- },
81
- },
82
- };
83
- }
@@ -1,66 +0,0 @@
1
- import { z } from 'zod';
2
- export declare function createExecTools(projectRoot: string): {
3
- hive_exec_start: {
4
- description: string;
5
- parameters: z.ZodObject<{
6
- task: z.ZodString;
7
- }, z.core.$strip>;
8
- execute: ({ task }: {
9
- task: string;
10
- }) => Promise<{
11
- error: string;
12
- worktreePath?: undefined;
13
- branch?: undefined;
14
- message?: undefined;
15
- } | {
16
- worktreePath: string;
17
- branch: string;
18
- message: string;
19
- error?: undefined;
20
- }>;
21
- };
22
- hive_exec_complete: {
23
- description: string;
24
- parameters: z.ZodObject<{
25
- task: z.ZodString;
26
- summary: z.ZodString;
27
- report: z.ZodOptional<z.ZodString>;
28
- }, z.core.$strip>;
29
- execute: ({ task, summary, report }: {
30
- task: string;
31
- summary: string;
32
- report?: string;
33
- }) => Promise<{
34
- error: string;
35
- completed?: undefined;
36
- task?: undefined;
37
- summary?: undefined;
38
- message?: undefined;
39
- } | {
40
- completed: boolean;
41
- task: string;
42
- summary: string;
43
- message: string;
44
- error?: undefined;
45
- }>;
46
- };
47
- hive_exec_abort: {
48
- description: string;
49
- parameters: z.ZodObject<{
50
- task: z.ZodString;
51
- }, z.core.$strip>;
52
- execute: ({ task }: {
53
- task: string;
54
- }) => Promise<{
55
- error: string;
56
- aborted?: undefined;
57
- task?: undefined;
58
- message?: undefined;
59
- } | {
60
- aborted: boolean;
61
- task: string;
62
- message: string;
63
- error?: undefined;
64
- }>;
65
- };
66
- };
@@ -1,125 +0,0 @@
1
- import * as path from 'path';
2
- import { z } from 'zod';
3
- import { TaskService } from '../services/taskService.js';
4
- import { FeatureService } from '../services/featureService.js';
5
- import { WorktreeService } from '../services/worktreeService';
6
- import { detectContext } from '../utils/detection.js';
7
- export function createExecTools(projectRoot) {
8
- const taskService = new TaskService(projectRoot);
9
- const featureService = new FeatureService(projectRoot);
10
- const worktreeService = new WorktreeService({
11
- baseDir: projectRoot,
12
- hiveDir: path.join(projectRoot, '.hive'),
13
- });
14
- const getActiveFeature = () => {
15
- const ctx = detectContext(projectRoot);
16
- return ctx?.feature || null;
17
- };
18
- return {
19
- hive_exec_start: {
20
- description: 'Create worktree and begin work on task',
21
- parameters: z.object({
22
- task: z.string().describe('Task folder name (e.g., "01-auth-service")'),
23
- }),
24
- execute: async ({ task }) => {
25
- const feature = getActiveFeature();
26
- if (!feature) {
27
- return { error: 'No active feature.' };
28
- }
29
- const featureData = featureService.get(feature);
30
- if (!featureData || featureData.status === 'planning') {
31
- return { error: 'Feature must be approved before starting execution.' };
32
- }
33
- const taskInfo = taskService.get(feature, task);
34
- if (!taskInfo) {
35
- return { error: `Task '${task}' not found` };
36
- }
37
- if (taskInfo.status === 'done') {
38
- return { error: `Task '${task}' is already completed` };
39
- }
40
- if (taskInfo.status === 'in_progress') {
41
- const existing = await worktreeService.get(feature, task);
42
- if (existing) {
43
- return {
44
- worktreePath: existing.path,
45
- branch: existing.branch,
46
- message: `Task already in progress. Worktree at ${existing.path}`,
47
- };
48
- }
49
- }
50
- const worktree = await worktreeService.create(feature, task);
51
- taskService.update(feature, task, { status: 'in_progress' });
52
- return {
53
- worktreePath: worktree.path,
54
- branch: worktree.branch,
55
- message: `Worktree created at ${worktree.path}. Work on branch ${worktree.branch}.`,
56
- };
57
- },
58
- },
59
- hive_exec_complete: {
60
- description: 'Complete task: apply changes, write report',
61
- parameters: z.object({
62
- task: z.string().describe('Task folder name'),
63
- summary: z.string().describe('Summary of what was done'),
64
- report: z.string().optional().describe('Detailed report (markdown). If not provided, summary is used.'),
65
- }),
66
- execute: async ({ task, summary, report }) => {
67
- const feature = getActiveFeature();
68
- if (!feature) {
69
- return { error: 'No active feature.' };
70
- }
71
- const taskInfo = taskService.get(feature, task);
72
- if (!taskInfo) {
73
- return { error: `Task '${task}' not found` };
74
- }
75
- if (taskInfo.status !== 'in_progress') {
76
- return { error: `Task '${task}' is not in progress (status: ${taskInfo.status})` };
77
- }
78
- const worktree = await worktreeService.get(feature, task);
79
- if (!worktree) {
80
- return { error: `No worktree found for task '${task}'` };
81
- }
82
- const diff = await worktreeService.getDiff(feature, task);
83
- if (diff) {
84
- await worktreeService.applyDiff(feature, task);
85
- }
86
- const reportContent = report || `# ${task}\n\n## Summary\n\n${summary}\n`;
87
- taskService.writeReport(feature, task, reportContent);
88
- taskService.update(feature, task, { status: 'done', summary });
89
- await worktreeService.remove(feature, task);
90
- return {
91
- completed: true,
92
- task,
93
- summary,
94
- message: `Task '${task}' completed. Changes applied to main branch.`,
95
- };
96
- },
97
- },
98
- hive_exec_abort: {
99
- description: 'Abort task: discard changes, reset status',
100
- parameters: z.object({
101
- task: z.string().describe('Task folder name'),
102
- }),
103
- execute: async ({ task }) => {
104
- const feature = getActiveFeature();
105
- if (!feature) {
106
- return { error: 'No active feature.' };
107
- }
108
- const taskInfo = taskService.get(feature, task);
109
- if (!taskInfo) {
110
- return { error: `Task '${task}' not found` };
111
- }
112
- if (taskInfo.status !== 'in_progress') {
113
- return { error: `Task '${task}' is not in progress` };
114
- }
115
- await worktreeService.remove(feature, task);
116
- taskService.update(feature, task, { status: 'pending' });
117
- return {
118
- aborted: true,
119
- task,
120
- message: `Task '${task}' aborted. Worktree removed, status reset to pending.`,
121
- };
122
- },
123
- },
124
- };
125
- }
@@ -1,60 +0,0 @@
1
- import { z } from 'zod';
2
- export declare function createFeatureTools(projectRoot: string): {
3
- hive_feature_create: {
4
- description: string;
5
- parameters: z.ZodObject<{
6
- name: z.ZodString;
7
- ticket: z.ZodOptional<z.ZodString>;
8
- }, z.core.$strip>;
9
- execute: ({ name, ticket }: {
10
- name: string;
11
- ticket?: string;
12
- }) => Promise<{
13
- name: string;
14
- status: import("../types.js").FeatureStatusType;
15
- path: string;
16
- message: string;
17
- }>;
18
- };
19
- hive_feature_list: {
20
- description: string;
21
- parameters: z.ZodObject<{}, z.core.$strip>;
22
- execute: () => Promise<{
23
- features: {
24
- name: string;
25
- status: string;
26
- taskCount: number;
27
- isActive: boolean;
28
- }[];
29
- active: string | null;
30
- }>;
31
- };
32
- hive_feature_complete: {
33
- description: string;
34
- parameters: z.ZodObject<{
35
- _placeholder: z.ZodBoolean;
36
- name: z.ZodOptional<z.ZodString>;
37
- }, z.core.$strip>;
38
- execute: ({ name }: {
39
- name?: string;
40
- }) => Promise<{
41
- error: string;
42
- pendingTasks?: undefined;
43
- completed?: undefined;
44
- name?: undefined;
45
- message?: undefined;
46
- } | {
47
- error: string;
48
- pendingTasks: string[];
49
- completed?: undefined;
50
- name?: undefined;
51
- message?: undefined;
52
- } | {
53
- completed: boolean;
54
- name: string;
55
- message: string;
56
- error?: undefined;
57
- pendingTasks?: undefined;
58
- }>;
59
- };
60
- };