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(hooks): defer installer metadata until hook generation [C1,I2]
Corey Olson3e345a5ef4e2
diff --git a/src/hooks.js b/src/hooks.jsindex 0bf3f505..b5f2334e 100644--- a/src/hooks.js+++ b/src/hooks.js@@ -659,8 +659,12 @@ export function pushesTrunk(refsText, trunk) {});}-/** The Pullboard version that writes the hooks, read once from the package it ships in. */-const INSTALLER_VERSION = JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8')).version;+let cachedInstallerVersion;++/** Read installer metadata only when generating a hook, so importing board helpers needs no package. */+function installerVersion() {+ return cachedInstallerVersion ??= JSON.parse(readFileSync(new URL('../package.json', import.meta.url), 'utf8')).version;+}/*** The shell script for one hook: it runs pullboard from this checkout's install, else the main@@ -676,7 +680,7 @@ const INSTALLER_VERSION = JSON.parse(readFileSync(new URL('../package.json', imp* @param {string} [version] The installing version; tests pass their own.* @returns {string}*/-export function hookScript(hook, version = INSTALLER_VERSION) {+export function hookScript(hook, version = installerVersion()) {const args = hook === 'commit-msg' ? ' "$message"' : '';return ['#!/bin/sh',