diff --git a/apps/server/src/provider/AntigravityInstallation.test.ts b/apps/server/src/provider/AntigravityInstallation.test.ts index dcd3e40030093..a9d98adf217ab 100644 --- a/apps/server/src/provider/AntigravityInstallation.test.ts +++ b/apps/server/src/provider/AntigravityInstallation.test.ts @@ -1032,6 +1032,11 @@ it.layer(Layer.mergeAll(NodeServices.layer, NodeCrypto.layer))("Antigravity inst executablePath: alias, harnessPath: null, }); + expect(yield* installation.resolve(undefined, { PATH: cliDirectory })).toMatchObject({ + executablePath: alias, + harnessPath: null, + source: "path", + }); expect(yield* installation.resolve(other).pipe(Effect.flip)).toMatchObject({ operation: "resolve", }); diff --git a/apps/server/src/provider/AntigravityInstallation.ts b/apps/server/src/provider/AntigravityInstallation.ts index feb412867f2e4..7c33d909ad849 100644 --- a/apps/server/src/provider/AntigravityInstallation.ts +++ b/apps/server/src/provider/AntigravityInstallation.ts @@ -401,9 +401,11 @@ export const makeAntigravityInstallation = Effect.fn("AntigravityInstallation.ma ); return installed; } - for (const candidate of yield* commandCandidates(names.executable, processEnvironment)) { - const selected = yield* fromExternal(candidate, "path"); - if (selected) return selected; + for (const command of [names.executable, "agy"]) { + for (const candidate of yield* commandCandidates(command, processEnvironment)) { + const selected = yield* fromExternal(candidate, "path"); + if (selected) return selected; + } } return yield* installationError( "resolve",