Autonomous development for real products. Governed agents build from specs you approve, follow the rules you set, and nothing merges until another agent proves it. Your decisions, judgement and taste are the bar that work must clear. Declare your vision and let agents build it.
JavaScript agentic-codingai-agentsai-governanceautonomous-agentsclaude-codeclicode-reviewcodexcoding-agentsdeveloper-toolsgit-hooksllmlocal-firstmulti-agentsoftware-factoryspec-driven-developmentverificationvibe-coding
fix(init): hint at a missing gate only when the config has none [I1]
Corey Olsonfe9e5657a3b5
diff --git a/src/init.js b/src/init.jsindex 468dc1a5..fb721a48 100644--- a/src/init.js+++ b/src/init.js@@ -30,6 +30,20 @@ export function detectGate(root) {}}+/**+ * The gate the repo's config sets now, whoever wrote it, or empty when unreadable.+ *+ * @param {string} root+ * @returns {string}+ */+function configuredGate(root) {+ try {+ return String(JSON.parse(readFileSync(join(root, CONFIG_FILE), 'utf8')).gate ?? '').trim();+ } catch {+ return '';+ }+}+/*** Write a file only when it does not exist yet.*@@ -97,6 +111,8 @@ export function initRepo({ info, openBoardHere, register, closeBoard }) {closeBoard(board);}notes.push('opened the board in the git dir; this checkout is the coordinator');- if (!gate) notes.push('no gate yet: set "gate" in pullboard.json to the command that proves the build');+ if (!configuredGate(root)) {+ notes.push('no gate yet: set "gate" in pullboard.json to the command that proves the build');+ }return notes;}diff --git a/test/e2e.test.js b/test/e2e.test.jsindex 0a9cafdf..6589c6e8 100644--- a/test/e2e.test.js+++ b/test/e2e.test.js@@ -115,6 +115,7 @@ test('init writes config, spec, agent docs and hooks once, and never clobbers [IwriteFileSync(join(repo, 'pullboard.json'), JSON.stringify({ ...CONFIG, gate: 'mine' }));const second = box.run(repo, 'init');assert.match(second.out, /kept pullboard.json/);+ assert.doesNotMatch(second.out, /no gate yet/, 'the config already names a gate');assert.equal(JSON.parse(readFileSync(join(repo, 'pullboard.json'), 'utf8')).gate, 'mine');const agents = readFileSync(join(repo, 'AGENTS.md'), 'utf8');assert.ok(agents.startsWith('# Mine\n\nkeep me\n'));