@codemcp/workflows-opencode 6.13.5 → 6.14.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/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  import { z } from 'zod';
2
+ import { Effect } from 'effect';
2
3
 
3
4
  /**
4
5
  * OpenCode Plugin Types
@@ -42,6 +43,7 @@ type PluginInput = {
42
43
  serverUrl: URL;
43
44
  $: unknown;
44
45
  };
46
+
45
47
  type ToolContext = {
46
48
  sessionID: string;
47
49
  messageID: string;
@@ -58,7 +60,7 @@ type ToolContext = {
58
60
  patterns: string[];
59
61
  always: string[];
60
62
  metadata: Record<string, unknown>;
61
- }): Promise<void>;
63
+ }): Effect.Effect<void>;
62
64
  };
63
65
  type ToolDefinition = {
64
66
  description: string;
package/dist/index.js CHANGED
@@ -6790,6 +6790,9 @@ var require_dist = __commonJS({
6790
6790
  }
6791
6791
  });
6792
6792
 
6793
+ // src/plugin.ts
6794
+ import { Effect } from "effect";
6795
+
6793
6796
  // src/tool-handlers/proceed-to-phase.ts
6794
6797
  import { z as z5 } from "zod";
6795
6798
 
@@ -28965,7 +28968,7 @@ ${phaseInstructions}`
28965
28968
  * an error if the agent is not allowed to use workflows.
28966
28969
  */
28967
28970
  tool: await (async () => {
28968
- const wrap = (def) => ({
28971
+ const wrap = (toolName, def) => ({
28969
28972
  ...def,
28970
28973
  execute: async (args, ctx) => {
28971
28974
  const agent = ctx.agent;
@@ -28974,11 +28977,20 @@ ${phaseInstructions}`
28974
28977
  `Workflows are not enabled for this agent (${agent}). Set WORKFLOW_AGENTS environment variable to include this agent, or use a different agent.`
28975
28978
  );
28976
28979
  }
28980
+ await Effect.runPromise(
28981
+ ctx.ask({
28982
+ permission: toolName,
28983
+ patterns: ["*"],
28984
+ always: ["*"],
28985
+ metadata: {}
28986
+ })
28987
+ );
28977
28988
  return def.execute(args, ctx);
28978
28989
  }
28979
28990
  });
28980
28991
  return {
28981
28992
  start_development: wrap(
28993
+ "start_development",
28982
28994
  createStartDevelopmentTool(
28983
28995
  input.directory,
28984
28996
  getServerContext,
@@ -28986,6 +28998,7 @@ ${phaseInstructions}`
28986
28998
  )
28987
28999
  ),
28988
29000
  proceed_to_phase: wrap(
29001
+ "proceed_to_phase",
28989
29002
  createProceedToPhaseTool(
28990
29003
  getServerContext,
28991
29004
  setBufferedInstructions,
@@ -28993,11 +29006,16 @@ ${phaseInstructions}`
28993
29006
  () => lastKnownModel
28994
29007
  )
28995
29008
  ),
28996
- conduct_review: wrap(createConductReviewTool(getServerContext)),
29009
+ conduct_review: wrap(
29010
+ "conduct_review",
29011
+ createConductReviewTool(getServerContext)
29012
+ ),
28997
29013
  reset_development: wrap(
29014
+ "reset_development",
28998
29015
  createResetDevelopmentTool(input.directory, getServerContext)
28999
29016
  ),
29000
29017
  setup_project_docs: wrap(
29018
+ "setup_project_docs",
29001
29019
  await createSetupProjectDocsTool(input.directory, getServerContext)
29002
29020
  )
29003
29021
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@codemcp/workflows-opencode",
3
- "version": "6.13.5",
3
+ "version": "6.14.1",
4
4
  "description": "OpenCode plugin for structured development workflows",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -16,18 +16,23 @@
16
16
  "zod": "^4.1.8"
17
17
  },
18
18
  "devDependencies": {
19
+ "effect": "3.21.1",
19
20
  "rimraf": "^6.0.1",
20
21
  "tsup": "^8.0.0",
21
22
  "vitest": "4.0.18",
22
- "@codemcp/workflows-core": "6.13.5",
23
- "@codemcp/workflows-server": "6.13.5"
23
+ "@codemcp/workflows-core": "6.14.1",
24
+ "@codemcp/workflows-server": "6.14.1"
24
25
  },
25
26
  "peerDependencies": {
26
- "@anthropic-ai/sdk": "*"
27
+ "@anthropic-ai/sdk": "*",
28
+ "effect": ">=3.0.0"
27
29
  },
28
30
  "peerDependenciesMeta": {
29
31
  "@anthropic-ai/sdk": {
30
32
  "optional": true
33
+ },
34
+ "effect": {
35
+ "optional": true
31
36
  }
32
37
  },
33
38
  "keywords": [