fix: allow file:../core in version check

This commit is contained in:
mkorwel
2025-07-01 11:25:10 -05:00
parent 2fe926308c
commit 1b59816570
+4 -3
View File
@@ -30,10 +30,11 @@ if (root.version !== cli.version || root.version !== core.version) {
} }
// 2. Check that the cli's dependency on core matches the core version. // 2. Check that the cli's dependency on core matches the core version.
const coreDepVersion = cli.dependencies['@google/gemini-core']; const coreDepVersion = cli.dependencies['@google/gemini-cli-core'];
if (coreDepVersion !== `^${core.version}`) { const expectedCoreVersion = `^${core.version}`;
if (coreDepVersion !== expectedCoreVersion && coreDepVersion !== 'file:../core') {
errors.push( errors.push(
`CLI dependency on core is wrong: expected ^${core.version}, got ${coreDepVersion}`, `CLI dependency on core is wrong: expected ${expectedCoreVersion} or "file:../core", got ${coreDepVersion}`,
); );
} else { } else {
console.log( console.log(