@controlvector/cv-agent 0.1.0 → 0.1.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/bundle.cjs CHANGED
@@ -4042,23 +4042,38 @@ ${task.input.context}`;
4042
4042
  `;
4043
4043
  });
4044
4044
  }
4045
- if (task.owner && task.repo) {
4046
- prompt += `
4045
+ prompt += `
4047
4046
 
4048
- ## Git Remote Instructions
4047
+ ## Git & CV-Hub Instructions
4048
+ `;
4049
+ prompt += `You have the \`cv\` CLI (@controlvector/cv-git) available for all CV-Hub git operations.
4050
+ `;
4051
+ prompt += `Use \`cv\` instead of raw \`git\` commands when interacting with CV-Hub repositories:
4049
4052
  `;
4050
- prompt += `This repository has a \`cvhub\` remote pointing to CV-Hub.
4053
+ prompt += ` cv push # push to CV-Hub
4051
4054
  `;
4052
- prompt += `When committing and pushing, push to the \`cvhub\` remote:
4055
+ prompt += ` cv pr create --title "..." # create pull request
4056
+ `;
4057
+ prompt += ` cv issue list # list issues
4058
+ `;
4059
+ prompt += ` cv repo info # repo details
4060
+ `;
4061
+ prompt += `
4053
4062
  `;
4054
- prompt += ` git push cvhub <branch>
4063
+ prompt += `For standard git operations (commit, branch, diff, log, status), use regular \`git\` commands.
4055
4064
  `;
4065
+ if (task.owner && task.repo) {
4056
4066
  prompt += `
4067
+ Target repository: ${task.owner}/${task.repo}
4057
4068
  `;
4058
- prompt += `IMPORTANT: Use only standard \`git\` commands. Do NOT use \`cv\`, \`cva\`, or \`cv-git\` commands.
4069
+ if (task.branch) prompt += `Target branch: ${task.branch}
4059
4070
  `;
4060
4071
  }
4061
4072
  prompt += `
4073
+ `;
4074
+ prompt += `IMPORTANT: Do NOT run \`cva\` commands. The \`cva\` binary is the agent daemon that launched you \u2014 calling it would cause recursion.
4075
+ `;
4076
+ prompt += `
4062
4077
 
4063
4078
  ---
4064
4079
  `;
@@ -4276,6 +4291,13 @@ async function runAgent(options) {
4276
4291
  console.log();
4277
4292
  process.exit(1);
4278
4293
  }
4294
+ try {
4295
+ (0, import_node_child_process2.execSync)("cv --version", { stdio: "pipe", timeout: 5e3 });
4296
+ } catch {
4297
+ console.log(source_default.yellow("!") + " cv-git CLI not found. Claude Code will fall back to raw git commands.");
4298
+ console.log(` Install it: ${source_default.cyan("npm install -g @controlvector/cv-git")}`);
4299
+ console.log();
4300
+ }
4279
4301
  const machineName = options.machine || await getMachineName();
4280
4302
  const pollInterval = Math.max(3, parseInt(options.pollInterval, 10)) * 1e3;
4281
4303
  const workingDir = options.workingDir;