MCPcopy
hub / github.com/codeaashu/claude-code / checkBridgeMinVersion

Function checkBridgeMinVersion

src/bridge/bridgeEnabled.ts:160–173  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

158 * loaded yet, the default '0.0.0' means the check passes — a safe fallback.
159 */
160export function checkBridgeMinVersion(): string | null {
161 // Positive pattern — see docs/feature-gating.md.
162 // Negative pattern (if (!feature(...)) return) does not eliminate
163 // inline string literals from external builds.
164 if (feature('BRIDGE_MODE')) {
165 const config = getDynamicConfig_CACHED_MAY_BE_STALE<{
166 minVersion: string
167 }>('tengu_bridge_min_version', { minVersion: '0.0.0' })
168 if (config.minVersion && lt(MACRO.VERSION, config.minVersion)) {
169 return `Your version of Claude Code (${MACRO.VERSION}) is too old for Remote Control.\nVersion ${config.minVersion} or higher is required. Run \`claude update\` to update.`
170 }
171 }
172 return null
173}
174
175/**
176 * Default for remoteControlAtStartup when the user hasn't explicitly set it.

Callers 3

initReplBridgeFunction · 0.85
checkBridgePrerequisitesFunction · 0.85
mainFunction · 0.85

Calls 3

featureFunction · 0.85
ltFunction · 0.85

Tested by

no test coverage detected