mirror of
https://github.com/harivansh-afk/clanker-agent.git
synced 2026-04-15 13:03:43 +00:00
refactor: finish companion rename migration
Complete the remaining pi-to-companion rename across companion-os, web, vm-orchestrator, docker, and archived fixtures. Verification: - semantic rg sweeps for Pi/piConfig/getPi/.pi runtime references - npm run check in apps/companion-os (fails in this worktree: biome not found) Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
parent
e8fe3d54af
commit
536241053c
303 changed files with 3603 additions and 3602 deletions
|
|
@ -4,7 +4,7 @@
|
|||
* optionally spawns subagents to analyze patterns.
|
||||
*
|
||||
* Usage: npx tsx scripts/session-transcripts.ts [--analyze] [--output <dir>] [cwd]
|
||||
* --analyze Spawn pi subagents to analyze each transcript file
|
||||
* --analyze Spawn companion subagents to analyze each transcript file
|
||||
* --output <dir> Output directory for transcript files (defaults to ./session-transcripts)
|
||||
* cwd Working directory to extract sessions for (defaults to current)
|
||||
*/
|
||||
|
|
@ -94,7 +94,7 @@ function runSubagent(
|
|||
): Promise<{ success: boolean }> {
|
||||
return new Promise((resolve) => {
|
||||
const child = spawn(
|
||||
"pi",
|
||||
"companion",
|
||||
["--mode", "json", "--tools", "read,write", "-p", prompt],
|
||||
{
|
||||
cwd,
|
||||
|
|
@ -158,7 +158,7 @@ function runSubagent(
|
|||
});
|
||||
|
||||
child.on("error", (err) => {
|
||||
console.error(chalk.red(` Failed to spawn pi: ${err.message}`));
|
||||
console.error(chalk.red(` Failed to spawn companion: ${err.message}`));
|
||||
resolve({ success: false });
|
||||
});
|
||||
});
|
||||
|
|
@ -188,7 +188,7 @@ async function main() {
|
|||
const cwd = resolve(cwdArg || process.cwd());
|
||||
|
||||
mkdirSync(outputDir, { recursive: true });
|
||||
const sessionsBase = join(homedir(), ".pi/agent/sessions");
|
||||
const sessionsBase = join(homedir(), ".companion/agent/sessions");
|
||||
const sessionDirName = cwdToSessionDir(cwd);
|
||||
const sessionDir = join(sessionsBase, sessionDirName);
|
||||
|
||||
|
|
@ -281,13 +281,13 @@ async function main() {
|
|||
|
||||
if (!analyzeFlag) {
|
||||
console.log(
|
||||
"\nRun with --analyze to spawn pi subagents for pattern analysis.",
|
||||
"\nRun with --analyze to spawn companion subagents for pattern analysis.",
|
||||
);
|
||||
return;
|
||||
}
|
||||
|
||||
// Find AGENTS.md files to compare against
|
||||
const globalAgentsMd = join(homedir(), ".pi/agent/AGENTS.md");
|
||||
const globalAgentsMd = join(homedir(), ".companion/agent/AGENTS.md");
|
||||
const localAgentsMd = join(cwd, "AGENTS.md");
|
||||
const agentsMdFiles = [globalAgentsMd, localAgentsMd].filter(existsSync);
|
||||
const agentsMdSection =
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue