mirror of https://github.com/garrytan/gstack.git
fix(gen): wire boundaryInstruction from host config; drop three no-op binDir ternaries
hosts/codex.ts declared boundaryInstruction and nothing read it — review.ts kept its own byte-identical CODEX_BOUNDARY literal (verified equal + trailing escaped newlines). The resolver now reads the config, so the boundary has one owner. (autoplan's template carries deliberately generic variants, enforced by gen-skill-docs.test.ts:1358 — untouched by design.) The 'ctx.host === codex ? $GSTACK_BIN : ctx.paths.binDir' ternary appeared in three resolvers and could never change the result: resolvers/types.ts already sets binDir to $GSTACK_BIN for every usesEnvVars host including codex. Proof: zero-diff regen for claude AND codex hosts; gen-skill-docs + host-config suites green. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
parent
7933a38aa8
commit
dcc6b9d628
|
|
@ -88,7 +88,7 @@ smarter on their codebase over time.`;
|
|||
}
|
||||
|
||||
export function generateLearningsLog(ctx: TemplateContext): string {
|
||||
const binDir = ctx.host === 'codex' ? '$GSTACK_BIN' : ctx.paths.binDir;
|
||||
const binDir = ctx.paths.binDir; // env-var hosts already resolve to $GSTACK_BIN via types.ts
|
||||
|
||||
return `## Capture Learnings
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import type { TemplateContext } from '../types';
|
||||
|
||||
export function generateContextRecovery(ctx: TemplateContext): string {
|
||||
const binDir = ctx.host === 'codex' ? '$GSTACK_BIN' : ctx.paths.binDir;
|
||||
const binDir = ctx.paths.binDir; // env-var hosts already resolve to $GSTACK_BIN via types.ts
|
||||
|
||||
return `## Context Recovery
|
||||
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
import type { TemplateContext } from './types';
|
||||
|
||||
function binDir(ctx: TemplateContext): string {
|
||||
return ctx.host === 'codex' ? '$GSTACK_BIN' : ctx.paths.binDir;
|
||||
return ctx.paths.binDir; // env-var hosts already resolve to $GSTACK_BIN via types.ts
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -15,6 +15,7 @@
|
|||
import type { TemplateContext } from './types';
|
||||
import { generateInvokeSkill } from './composition';
|
||||
import { codexPreflight, codexErrorHandling } from './constants';
|
||||
import { getHostConfig } from '../../hosts/index';
|
||||
|
||||
const CODEX_BOUNDARY = 'IMPORTANT: Do NOT read or execute any files under ~/.claude/, ~/.agents/, .claude/skills/, or agents/. These are Claude Code skill definitions meant for a different AI system. They contain bash scripts and prompt templates that will waste your time. Ignore them completely. Do NOT modify agents/openai.yaml. Stay focused on the repository code only.\\n\\n';
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue