@brainervirus/workit-cursor 2.5.0 → 2.6.0

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.
@@ -2,7 +2,7 @@
2
2
  "name": "workit",
3
3
  "displayName": "Workit",
4
4
  "description": "Adaptive Workit workflow with shared MCP tools and native Cursor hooks",
5
- "version": "2.5.0",
5
+ "version": "2.6.0",
6
6
  "author": {
7
7
  "name": "Cristhofer Pincetti"
8
8
  },
@@ -15453,10 +15453,7 @@ function handleHook(input, deps) {
15453
15453
  case "shell.pre":
15454
15454
  return usable2(descriptor.shellPolicy.deny) ? shellPolicy(input.cwd, event.command) : NONE2;
15455
15455
  case "subagent.start":
15456
- return {
15457
- kind: "context",
15458
- text: `Workit observed ${descriptor.label} subagent ${event.agentId} (${event.agentType}) as read-only/agent-guided; writer delegation is unavailable.`
15459
- };
15456
+ return { kind: "context", text: subagentStartText(input.host, descriptor, event) };
15460
15457
  case "compact.pre":
15461
15458
  return {
15462
15459
  kind: "notice",
@@ -15470,7 +15467,7 @@ function handleHook(input, deps) {
15470
15467
  return NONE2;
15471
15468
  }
15472
15469
  }
15473
- var usable2 = (value) => value === "native" || value === "partial", NONE2, offered, failureDecision = (descriptor, event, error) => {
15470
+ var usable2 = (value) => value === "native" || value === "partial", NONE2, offered, CLAUDE_WORKTREE_IMPLEMENTER = "workit:implementer", subagentStartText = (host, descriptor, event) => host === "claude_code" && event.agentType === CLAUDE_WORKTREE_IMPLEMENTER ? `Workit observed ${descriptor.label} subagent ${event.agentId} (${event.agentType}) working in its own git worktree: it may edit and commit there, within its brief's scope. Before the first commit, switch to a policy-compliant branch (\`git switch -c <type>/<slug>\`, e.g. feature/<slug>); branch policy hooks still deny protected or non-compliant branches. Never push, open a PR, or merge unless the brief asks for it.` : `Workit observed ${descriptor.label} subagent ${event.agentId} (${event.agentType}) as read-only/agent-guided; writer delegation is unavailable.`, failureDecision = (descriptor, event, error) => {
15474
15471
  if (event === "shell.pre" || event === "tool.pre")
15475
15472
  return descriptor.shellPolicy.failClosed ? { kind: "deny", reason: error, unblock: null } : NONE2;
15476
15473
  if (event === "session.start" || event === "subagent.start")
@@ -15421,6 +15421,8 @@ var shellPolicy = (cwd, command) => {
15421
15421
  var usable2 = (value) => value === "native" || value === "partial";
15422
15422
  var NONE2 = { kind: "none" };
15423
15423
  var offered = new Set;
15424
+ var CLAUDE_WORKTREE_IMPLEMENTER = "workit:implementer";
15425
+ var subagentStartText = (host, descriptor, event) => host === "claude_code" && event.agentType === CLAUDE_WORKTREE_IMPLEMENTER ? `Workit observed ${descriptor.label} subagent ${event.agentId} (${event.agentType}) working in its own git worktree: it may edit and commit there, within its brief's scope. Before the first commit, switch to a policy-compliant branch (\`git switch -c <type>/<slug>\`, e.g. feature/<slug>); branch policy hooks still deny protected or non-compliant branches. Never push, open a PR, or merge unless the brief asks for it.` : `Workit observed ${descriptor.label} subagent ${event.agentId} (${event.agentType}) as read-only/agent-guided; writer delegation is unavailable.`;
15424
15426
  function handleHook(input, deps) {
15425
15427
  const { descriptor } = deps;
15426
15428
  const event = input.event;
@@ -15446,10 +15448,7 @@ function handleHook(input, deps) {
15446
15448
  case "shell.pre":
15447
15449
  return usable2(descriptor.shellPolicy.deny) ? shellPolicy(input.cwd, event.command) : NONE2;
15448
15450
  case "subagent.start":
15449
- return {
15450
- kind: "context",
15451
- text: `Workit observed ${descriptor.label} subagent ${event.agentId} (${event.agentType}) as read-only/agent-guided; writer delegation is unavailable.`
15452
- };
15451
+ return { kind: "context", text: subagentStartText(input.host, descriptor, event) };
15453
15452
  case "compact.pre":
15454
15453
  return {
15455
15454
  kind: "notice",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brainervirus/workit-cursor",
3
- "version": "2.5.0",
3
+ "version": "2.6.0",
4
4
  "private": false,
5
5
  "description": "Workit Cursor plugin — shared MCP transport, native hooks, and fourteen method skills",
6
6
  "keywords": [
@@ -44,8 +44,8 @@
44
44
  "build": "bun scripts/build.ts"
45
45
  },
46
46
  "dependencies": {
47
- "@brainervirus/workit-core": "^2.5.0",
48
- "@brainervirus/workit-mcp": "^2.5.0"
47
+ "@brainervirus/workit-core": "^2.6.0",
48
+ "@brainervirus/workit-mcp": "^2.6.0"
49
49
  },
50
50
  "engines": {
51
51
  "node": ">=24"